code: def load_file(filename):
      delimiters = {".tsv": "\t", ".csv": ","}
      _, ext = os.path.splitext(filename)
  
      if ext not in delimiters:
          raise RuntimeError(
              "Filetype not recognised (expected .csv or .tsv): %s"
              % ext
          )
  
      df = pandas.read_csv(filename, sep=delimiters[ext])
  
      xs = np.array(df[FLAGS.xkey])
  
      if FLAGS.smoothing == "pandas":
          window = df[FLAGS.ykey].rolling(
              window=FLAGS.window, min_periods=0
          )
          ys = np.array(window.mean())
      else:
          ys = np.array(df[FLAGS.ykey])
          xs, ys = rolling_xs_ys(xs, ys, window_size=FLAGS.window)
  
      return (xs, ys, {"legend": filename})
  
file_path: moolib/py/moolib/examples/plot.py
imports: import argparse
  import glob
  import os
  import gnuplotlib
  import numpy
  import pandas
label_desc: Use image node_id 5 for calling a global function with example usage: load_file(filename) and returns: xs,  ys,  dict