code: def save_data(self, filename):
          
          with zopen(filename, "wt") as f:
              json.dump(list(self._data), f, cls=MontyEncoder)
docs: Save the assimilated data to a file.
  
          Args:
              filename (str): filename to save the assimilated data to. Note
                  that if the filename ends with gz or bz2, the relevant gzip
                  or bz2 compression will be applied.