This preview shows pages 1–3. Sign up to view the full content.
This preview has intentionally blurred sections. Sign up to view the full version.
View Full Document
Unformatted text preview: TA session 5 Econ. 103, winter 2010 Wed., Feb. 3, 2010, 10:00 a.m. and 1:00 p.m. in PP2400E. 1 Verbose implementation of HW2 Q5 1.1 Summary stats for Californians count if ca==1 gives the count of those who say they are Californians: 99 sum colgpa if ca==1 gives the summary stats requested. You should see: Variable  Obs Mean Std. Dev. Min Max+ colgpa  95 3.528547 .2569961 2.8 3.94 Why are there 95 observations of colgpa for Californians but a total of 99 who say they are from California? It is because some people did not report their GPA. Try typing count if ca==1 & colgpa==. The ampersand & is used to express the logical and when you give Stata logical con ditions for the execution of some command. For example, try sum age if colgpa>=3.5 & ca==1 . 1.2 Summary stats for outofstaters count if ca==0 gives the count of those who say they arent Californians: 27 sum colgpa if ca==0 gives the summary stats requested. You should see: Variable  Obs Mean Std. Dev. Min Max+ colgpa  27 3.612481 .2987732 3 4 1.3 Confidence interval for the difference of the two populations expected college GPA Recall a confidence interval is constructed from estimates of the mean and standard deviation. A critical value c for the confidence interval is chosen as a function of the level of significance . The confidence interval is wider for big c and smaller for small c . Its formula is bracketleftbigg  c n , + c n bracketrightbigg I gave you a table in notes 43 to help you decide from which distribution we select the critical value. In practice, since the sample size is almost always n 30, we draw it from the normal. And you do not have to think about this anyway since Stata does it for you. 1 ttest colgpa, by(ca) level(90) this conducts a ttest and, along the way, it also gives you pvalues and forms the confidence interval. All in all, a useful command: Twosample t test with equal variances Group  Obs Mean Std. Err. Std. Dev. [90% Conf. Interval]+...
View
Full
Document
 Winter '07
 SandraBlack
 Econometrics

Click to edit the document details