No announcement yet.
  • Filter
  • Time
  • Show
Clear All
new posts

  • Combining balance tables: descriptive stats and regression output for multiple treatment groups

    Hi all,

    I'm trying to create a table with balance tests for a randomised trial with three treatment groups. I would like to display the mean and sd of the four groups (Control, T1, T2, T3) in the first four columns, and the p-values on difference in means in the columns next to it (Tests of Equality performed through OLS regressions).

    It should looks like this:

    | Control T1 T2 T3 ToE [C=T1] ToE [C=T2] ToE [C=T3] ToE [T1=T2] ToE [T2=T3]
    var1 | mean mean mean mean [p-value] [p-value] [p-value] [p-value] [p-value]
    | (sd) (sd) (sd) (sd)
    var2 | mean mean mean mean [p-value] [p-value] [p-value] [p-value] [p-value]
    | (sd) (sd) (sd) (sd)
    var3 | mean mean mean mean [p-value] [p-value] [p-value] [p-value] [p-value]
    | (sd) (sd) (sd) (sd)
    var4 | mean mean mean mean [p-value] [p-value] [p-value] [p-value] [p-value]
    | (sd) (sd) (sd) (sd)
    varX | mean mean mean mean [p-value] [p-value] [p-value] [p-value] [p-value]
    | (sd) (sd) (sd) (sd)

    I'm familiar with -estout- and -outreg- packages but these don't give me the result I want so far. I'm looking into -frmttable- to to merge tables, but could really use some input from more experienced matrix programmers. I want to output into excel at first, and later also tex. Any help would be much appreciated!


  • #2
    I realise the table does not turn out well, find desired format attached in Excel.

    Attached Files