TABLE2LATEX

TABLE2LATEX converts a table to the tabular form for use in LaTeX.
397 Downloads
Updated 8 Nov 2020
table2latex converts a table to the tabular form for use in LaTeX.
Input args
T: a table of elements
selectedCols: index vector of table columns that need to be
printed. Default: All columns.
label: the label for references to the table. Default: Empty.
caption: the caption of the table. Default: Empty.
colWidths: the widths for each column. Default: Equally adjusted
width.
isLandscape: flag to rotate table to landscape mode. Default:
Vertical mode.
notes: a cell array of additional notes after the table. Default: Not
used.
isAfterpage: flag to execute commands after pagebreak. Default: no
afterpage.
Output args
Ttex: the formatted text for the table
Dependencies
None
LaTeX requirements for landscape view:
\usepackage{afterpage}
\usepackage{pdflscape} %rotates page
LaTeX requirements for table notes:
\usepackage[flushleft]{threeparttable}
Usage
Ttex = table2latex(T);
Ttex = table2latex(T, [1:5]);
Ttex = table2latex(T, [], 'tab:table1', 'Experimental Values', [], false, {'These are example values.'}, false);
The function prints the formatted table, which then
can be copied and pasted to LaTeX as is.
Created by foxelas [https://github.com/foxelas/] (2022)

Cite As

ELENI ALOUPOGIANNI (2024). TABLE2LATEX (https://github.com/foxelas/Matlab-assisting-functions/releases/tag/3.0), GitHub. Retrieved .

MATLAB Release Compatibility
Created with R2019b
Compatible with any release
Platform Compatibility
Windows macOS Linux
Tags Add Tags

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!
Version Published Release Notes
3.0

See release notes for this release on GitHub: https://github.com/foxelas/Matlab-assisting-functions/releases/tag/3.0

To view or report issues in this GitHub add-on, visit the GitHub Repository.
To view or report issues in this GitHub add-on, visit the GitHub Repository.