seqme.to_latex

Contents

seqme.to_latex#

seqme.to_latex(df, path, *, n_decimals=2, color=None, na_value='-', show_arrow=True, width=None, caption=None, label='tbl:benchmark')[source]#

Export a metric dataframe to a LaTeX table.

Parameters:
  • df (DataFrame) – Metric dataframe.

  • path (str | Path) – Output filename, e.g., "./path/table.tex".

  • n_decimals (int | list[int]) – Decimal precision for formatting. Value is rounded. Deviation is rounded up.

  • color (Optional[str]) – Color for highlighting best scores. If None, no coloring.

  • na_value (str) – Text to show for cells with no metric value, i.e., cells with NaN values.

  • show_arrow (bool) – Whether to include the objective arrow in the column names.

  • width (Optional[float]) – Table width as a fraction of the text width. If None, use default width.

  • caption (Optional[str]) – Bottom caption text. If None, no caption is added.

  • label (str | None) – Table label. Identifier used to reference the table. If None, no label is added.