Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

Re: st: Question on Ttest.

From   Richard Williams <>
Subject   Re: st: Question on Ttest.
Date   Fri, 21 Nov 2003 08:09:57 -0500

At 12:47 PM 11/21/2003 +0000, Joao Pedro W. de Azevedo wrote:
Dear Statausers,
I'm doing a simple ttest, however I would like to retrive the Std. Deviation
of the difference of the means (see output below). Does anyone know if Stata
saves this statistic?
Many thanks,

. ttest  match2291_0== match2291_1 if week>=2144
I'm not a heavy-duty Stata user and somebody may be able to give you exactly the answer you want. But, given that this is matched pairs, I think you might be able to improvise as follows:

. gen diff2291 = match2291_0 - match2291_1
. ttest diff2291 == 0 if week>=2144

In other words, compute the difference between the two scores and then do a 1-sample t-test of whether the mean of that difference is zero. From that retrieve the standard error of the difference.

Richard Williams, Associate Professor
OFFICE: (574)631-6668, (574)631-6463
FAX: (574)288-4373
HOME: (574)289-5227
EMAIL: Richard.A.Williams.5@ND.Edu
WWW (personal):
WWW (department):

* For searches and help try:

© Copyright 1996–2022 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index