code: def graph_process(fields):
      '''process for a graph'''
      mestate.mlog.reduce_by_flightmodes(mestate.flightmode_selections)
      
      mg = grapher.MavGraph()
      mg.set_marker(mestate.settings.marker)
      mg.set_condition(mestate.settings.condition)
      mg.set_xaxis(mestate.settings.xaxis)
      mg.set_linestyle(mestate.settings.linestyle)
      mg.set_flightmode(mestate.settings.flightmode)
      mg.set_legend(mestate.settings.legend)
      mg.add_mav(mestate.mlog)
      for f in fields:
          mg.add_field(f)
      mg.process()
      mg.show(f graph_process(fields):
      '''process for a graph'''
      mestate.mlog.reduce_by_flightmodes(mestate.flightmode_selections)
      
      mg = grapher.MavGraph()
      mg.set_marker(mestate.settings.marker)
      mg.set_condition(mestate.settings.condition)
      mg.set_xaxis(mestate.settings.xaxis)
      mg.set_linestyle(mestate.settings.linestyle)
      mg.set_flightmode(mestate.settings.flightmode)
      mg.set_legend(mestate.settings.legend)
      mg.add_mav(mestate.mlog)
      for f in fields:
          mg.add_field(f)
      mg.process()
      mg.show()
docs: process for a graph