Hi all,
I'm trying to compare two differences from two separate t-tests and whether those differences are statistically different. Perhaps better explained by an example:
So I want to see if the first difference between males and females, -20.38386 is statistically difference from the second difference -10.5354.
How would I go about doing this?
Any advice would be great, thanks!
I'm trying to compare two differences from two separate t-tests and whether those differences are statistically different. Perhaps better explained by an example:
Code:
. ttest absdays_totalcombined_c if treatedpost_control == 0 , by(gender)
Two-sample t test with equal variances
------------------------------------------------------------------------------
Group | Obs Mean Std. Err. Std. Dev. [95% Conf. Interval]
---------+--------------------------------------------------------------------
male | 693 14.21356 .6848489 18.02857 12.86893 15.5582
female | 698 34.59742 1.384127 36.56821 31.87986 37.31498
---------+--------------------------------------------------------------------
combined | 1,391 24.44213 .8204359 30.59907 22.8327 26.05155
---------+--------------------------------------------------------------------
diff | -20.38386 1.547674 -23.41989 -17.34783
------------------------------------------------------------------------------
diff = mean(male) - mean(female) t = -13.1706
Ho: diff = 0 degrees of freedom = 1389
Ha: diff < 0 Ha: diff != 0 Ha: diff > 0
Pr(T < t) = 0.0000 Pr(|T| > |t|) = 0.0000 Pr(T > t) = 1.0000
. ttest absdays_totalcombined_c if treatedpost_control == 1 , by(gender)
Two-sample t test with equal variances
------------------------------------------------------------------------------
Group | Obs Mean Std. Err. Std. Dev. [95% Conf. Interval]
---------+--------------------------------------------------------------------
male | 168 16.28571 1.442317 18.69456 13.43819 19.13324
female | 190 26.82105 2.321296 31.99685 22.24208 31.40003
---------+--------------------------------------------------------------------
combined | 358 21.87709 1.431116 27.07799 19.06262 24.69157
---------+--------------------------------------------------------------------
diff | -10.53534 2.816868 -16.07513 -4.995544
------------------------------------------------------------------------------
diff = mean(male) - mean(female) t = -3.7401
Ho: diff = 0 degrees of freedom = 356
Ha: diff < 0 Ha: diff != 0 Ha: diff > 0
Pr(T < t) = 0.0001 Pr(|T| > |t|) = 0.0002 Pr(T > t) = 0.9999
How would I go about doing this?
Any advice would be great, thanks!

Comment