The summary table in stata outputs with the industry names along the top as columns and the mean sd min max count as rows. I would like to export the table like this to Latex, but am struggling to do so currently. If I add c(stat) to the tabstat it solves the problem and exports to Latex, but then mean sd min max count are the columns, which I don't want. Please help! I have attached my data. Thank you in advance.
If possible, I would include the following summary tables as well (without the industry names at the top, so only the mean sd min max count). For the section of the table where ScheduledMeeting == ., I would like a label on the left-hand side stating "Non-Meeting Days", for ScheduledMeeting == 1 "Meeting Days", and ScheduledMeeting == 0 "Intermeeting Days". Thank you!
Though less important, if someone could also help me figure out the code to export the following table to Latex, that would be great.
[/CODE]
tabstat Change Surprise new_Surprise Expected new_Expected if ScheduledMeeting == 1, by(ChangeDirection) stats(mean sd count) columns(variables)
[/CODE]
Code:
eststo clear // Look at industry returns estpost tabstat market nodur durbl manuf enrgy hitec telcm shops hlth utils other if ScheduledMeeting == ., statistics(mean sd min max count) ***Now, Output with Specific Decimal Places #delimit ; esttab using outtex.tex, replace ///Replace file if already exists cells("mean(fmt(2)) sd(fmt(2)) min(fmt(2)) max(fmt(2)) count(fmt(0))") ///Which Stats to Output nonumber ///Do not put numbers below column titlles nomtitle ///This option mainly for regression tables booktabs ///Top, Mid, Bottom Rule noobs ///We don't need observation counts because count is N title("Industry Returns on Non-Meeting Days\label{tab1}") ///Latex number this for us collabels("Mean" "SD" "Min" "Max" "N") /// Name of each column ; eststo clear
If possible, I would include the following summary tables as well (without the industry names at the top, so only the mean sd min max count). For the section of the table where ScheduledMeeting == ., I would like a label on the left-hand side stating "Non-Meeting Days", for ScheduledMeeting == 1 "Meeting Days", and ScheduledMeeting == 0 "Intermeeting Days". Thank you!
Code:
tabstat market nodur durbl manuf enrgy hitec telcm shops hlth utils other if ScheduledMeeting == 1, statistics(count mean sd min max) tabstat market nodur durbl manuf enrgy hitec telcm shops hlth utils other if ScheduledMeeting == 0, statistics(count mean sd min max)
Though less important, if someone could also help me figure out the code to export the following table to Latex, that would be great.
[/CODE]
tabstat Change Surprise new_Surprise Expected new_Expected if ScheduledMeeting == 1, by(ChangeDirection) stats(mean sd count) columns(variables)
[/CODE]
Comment