Dear Statlist,
I am using the estout-package (package st0085_2 from http://www.stata-journal.com/software/sj14-2).
I am creating a regression table that I want to print via latex using the following command with a note:
esttab using "test.tex", note("very long note, longer than the breadth of my table")
I am including this table later in a LaTeX document using
\begin{table}[H]
\centering
\input{../test.tex}
\end{table}
=> is there a method how to automatically make sure that the note does a line break when appropriate? As of now the table gets the same breadth as my note, which requires me to manually correct every table I generate.
- I tried, as a workaround, note("very long note, line 1" "continued, line2") which does not work (and would not be optimal as I would have to make linebreaks manually in Stata then.
- I tried as a second workaround the postfoot command. The problem is that somehow with using "esttab using "test.tex", postfoot("very long note, longer than the breadth of my table")" the generated LaTeX-Table does not end properly.
So I had to write
esttab using "test.tex", replace postfoot("\hline\hline" "\end{tabular}" "}" "\\ \footnotesize{very long note, longer than the breadth of my table.}")
==> this works, but is of course tidious to implement for many tables.
Does anyone have an easier solution?
Best and thanks
Lukas
I am using the estout-package (package st0085_2 from http://www.stata-journal.com/software/sj14-2).
I am creating a regression table that I want to print via latex using the following command with a note:
esttab using "test.tex", note("very long note, longer than the breadth of my table")
I am including this table later in a LaTeX document using
\begin{table}[H]
\centering
\input{../test.tex}
\end{table}
=> is there a method how to automatically make sure that the note does a line break when appropriate? As of now the table gets the same breadth as my note, which requires me to manually correct every table I generate.
- I tried, as a workaround, note("very long note, line 1" "continued, line2") which does not work (and would not be optimal as I would have to make linebreaks manually in Stata then.
- I tried as a second workaround the postfoot command. The problem is that somehow with using "esttab using "test.tex", postfoot("very long note, longer than the breadth of my table")" the generated LaTeX-Table does not end properly.
So I had to write
esttab using "test.tex", replace postfoot("\hline\hline" "\end{tabular}" "}" "\\ \footnotesize{very long note, longer than the breadth of my table.}")
==> this works, but is of course tidious to implement for many tables.
Does anyone have an easier solution?
Best and thanks
Lukas
Comment