dump_df

dump_df(key: str, *subkeys: str, name: str, obj: pd.DataFrame, sep: str = '\t', index: bool = False, to_csv_kwargs: Mapping[str, Any] | None = None) None[source]

Dump a dataframe to a TSV file with pandas.

Parameters:
  • key – The module name

  • subkeys – A sequence of additional strings to join. If none are given, returns the directory for this module.

  • name – Overrides the name of the file at the end of the URL, if given. Also useful for URLs that don’t have proper filenames with extensions.

  • obj – The dataframe to dump

  • sep – The separator to use, defaults to a tab

  • index – Should the index be dumped? Defaults to false.

  • to_csv_kwargs – Keyword arguments to pass through to pandas.DataFrame.to_csv().