One and 2 sample t-test Exercises (4)

docx

School

Seneca College *

*We aren’t endorsed by this school

Course

120

Subject

Statistics

Date

Feb 20, 2024

Type

docx

Pages

7

Uploaded by DoctorBravery103687

Report
T-Test (Total 20 points) 1. Performing a One-Sample t -Test (10 points) The data in DATALIB.NormTemp comes from an article in the Journal of Statistics Education by Dr. Allen L. Shoemaker from the Psychology Department at Calvin College. The data are based on an article in a 1992 edition of JAMA ( Journal of the American Medical Association ), which questions the notion that the true mean body temperature is 98.6. There are 65 males and 65 females. There is also some question about whether mean body temperatures for women are the same as for men. The variables in the data set are as follows: ID Identification number BodyTemp Body temperature (degrees Fahrenheit) Gender Coded ( Male , Female ) HeartRate Heart rate (beats per minute) a. Look at the distribution of the continuous variables in the data set using PROC UNIVARIATE, including producing histograms and insets with means, standard deviations, and sample size. (2 points) b. Perform a one-sample t -test to determine whether the mean of body temperatures (the variable BodyTemp in DATALIB.NormTemp ) is 98.6. Produce a confidence interval plot of BodyTemp with the value 98.6 used as a reference. 1) What is the value of the t statistic and the corresponding p -value? (2 points) Answer- The t value is -5.45, and the p-value is <.0001. 2) Do you reject or fail to reject the null hypothesis at the 0.05 level that the average temperature is 98.6 degrees? (2 points) Answer- We reject the null hypothesis at the 0.05 level. c. Provide the syntax and output (4 points) Answer- libname DATALIB '/home/u63731080/DATALIB'; data DATALIB.normtemp; set '/home/u63731080/DATALIB/normtemp.sas7bdat'; run; TITLE 'Distribution Analysis Using PROC UNIVARIATE'; ods select histogram; proc univariate data=DATALIB.normtemp noprint; Var BodyTemp HeartRate; histogram BodyTemp HeartRate/ normal kernel; inset N MEAN STD / position=ne; run;
TITLE 'One-Sample t-test using PROC TTEST to test whether Mean BodyTemp=98.6'; proc ttest data=DATALIB.normtemp h0=98.6 plots(only shownull)=interval; var BodyTemp; run;
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
2. Using PROC TTEST for Comparing Groups (10 points) Elli Sagerman, a Masters of Education candidate in German Education at the University of North Carolina at Chapel Hill in 2000, collected data for a study. She looked at the effectiveness of a new type of foreign language teaching technique on grammar skills. She selected 30 students to receive tutoring; 15 received the new type of training during the tutorials and 15 received standard tutoring. Two students moved away from the district before completing the study. Scores on a standardized German grammar test were recorded immediately before the 12-week tutorials and then again 12 weeks later at the end of the trial. Sagerman wanted to see the effect of the new technique on grammar skills. The data are in the DATALIB.GERMAN data set. Change Change in grammar test scores Group The assigned treatment, coded Treatment and Control Analyze the data using PROC TTEST. Assess whether the treatment group improved more than the control group. a. Do the two groups appear to be approximately normally distributed? (2 points) Answer- Yes, the plots show evidence that supports approximate normality in both groups. b. Do the two groups have approximately equal variances? (2 points) Answer- The p-value for the equality of variances test is greater than 0.05 so, we do not reject null hypothesis which supports the assumption that the two graphs have approximately equal variances. c. Does the new teaching technique seem to result in significantly different change scores compared with the standard technique? (2 points) Answer- The p-value for the Pooled (Equal Variance) test for the difference between the two means has value greater than 0.05 which shows that the two groups are not statistically different.so, there is not enough evidence to say that the new teaching technique is significantly different from the old technique. d. Provide the syntax and output (4 points) Answer- libname DATALIB '/home/u63731080/DATALIB'; data DATALIB.german; set '/home/u63731080/DATALIB/german.sas7bdat'(keep=Change Group); run; TITLE 'Comparing Two groups: Treatment and Control'; proc ttest data=datalib.german plots= (interval qq) ; class Group; Var Change; run;
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help