              logger.debug("No save file. Returning")
              return
  
          logger.debug("Saving to: '%s'", savefile)
          with savefile as outfile:
              csvout = csv.DictWriter(outfile, fieldnames)
              csvout.writeheader()
              for row in self.summary:
 
</s> remove             for row in write_dicts:
 </s> add             for row in self.summary: </s> remove         write_dicts = [val for val in self.summary.values()]
        fieldnames = sorted(key for key in write_dicts[0].keys())

 </s> add 
        fieldnames = sorted(key for key in self.summary[0].keys())
              logger.debug("No save file. Returning")
              return
  
          logger.debug("Saving to: '%s'", savefile)
        fieldnames = sorted(key for key in self.summary[0].keys())
          with savefile as outfile:
              csvout = csv.DictWriter(outfile, fieldnames)
              csvout.writeheader()
              for row in self.summary:
keep keep keep add keep keep keep keep
 GUI Bugfix: Fix csv saving in analysis tab 
lib/gui/display_analysis.py