The question is in the title :-) Is it possible to make estout use \tabularnewline instead of \\ for new lines?
-
Login or Register
- Log in with
sysuse auto, clear
regress mpg weight disp, robust
esttab, tex
esttab, tex substitute(\\ "\tabularnewline")
. esttab, tex
{
\def\sym#1{\ifmmode^{#1}\else\(^{#1}\)\fi}
\begin{tabular}{l*{1}{c}}
\hline\hline
&\multicolumn{1}{c}{(1)}\\
&\multicolumn{1}{c}{mpg}\\
\hline
weight & -0.00657\sym{***}\\
& (-7.04) \\
[1em]
displacement& 0.00528 \\
& (0.71) \\
[1em]
\_cons & 40.08\sym{***}\\
& (19.33) \\
\hline
\(N\) & 74 \\
\hline\hline
\multicolumn{2}{l}{\footnotesize \textit{t} statistics in parentheses}\\
\multicolumn{2}{l}{\footnotesize \sym{*} \(p<0.05\), \sym{**} \(p<0.01\), \sym{***} \(p<0.001\)}\\
\end{tabular}
}
. esttab, tex substitute(\\ "\tabularnewline")
{
\def\sym#1{\ifmmode^{#1}\else\(^{#1}\)\fi}
\begin{tabular}{l*{1}{c}}
\hline\hline
&\multicolumn{1}{c}{(1)}\tabularnewline
&\multicolumn{1}{c}{mpg}\tabularnewline
\hline
weight & -0.00657\sym{***}\tabularnewline
& (-7.04) \tabularnewline
[1em]
displacement& 0.00528 \tabularnewline
& (0.71) \tabularnewline
[1em]
_cons & 40.08\sym{***}\tabularnewline
& (19.33) \tabularnewline
\hline
\(N\) & 74 \tabularnewline
\hline\hline
\multicolumn{2}{l}{\footnotesize \textit{t} statistics in parentheses}\tabularnewline
\multicolumn{2}{l}{\footnotesize \sym{*} \(p<0.05\), \sym{**} \(p<0.01\), \sym{***} \(p<0.001\)}\tabularnewline
\end{tabular}
}
.
Comment