Statistic Assignment
Statistic Assignment
Question 1) Based on the sample of Pulse1 find an estimate for the heart rate activity for the
population with a 95% level of confidence.
Answer) For this question I used R library Rmisc and its function CI to find an estimate for the
heart rate activity for the population with a 95% level of confidence. The result of this function
is shown below
From above table I observed that the mean value for a 95% confidence interval is 75.68807.
Question 2) It has been claimed that the average pulse rate is 75.2 beats per minute. Use an
appropriate test to determine if the first pulse measured (Pulse1) is greater than 75.2 bpm.
Answer) For this question I used t-test to check whether the first pulse measured (Pulse1) is
greater than 75.2bpm or not. The null hypothesis for this question is the first pulse measured
(Pulse1) is not greater than 75.2 bpm. The result of the t-test is shown below
The p-value of the test is 0.3512, which is greater than the significance level alpha = 0.05. We
can conclude that the mean value of Pulse1 is not greater than 75.2 bpm.
Question 3) Perform a suitable test to determine if the first pulse rate (Pulse1) differs between
Gender (Gender). In your analysis, examine Pulse1 across gender with appropriate descriptive
statistics and graphics. Assess each sample for normality. Assess equality of variance. State the
CI for the difference in means and interpret these values.
Answer) The table representing the mean value of Pulse1 across Gender is shown below:
I used box plot to represent the distribution of Pulse1 across Gender. The box plot representing
this information is shown below:
I applied Shapiro-Wilk normality test for assessing the normality of pulse 1 for Male and
Female. The Null hypothesis for Shapiro-Wilk test: the data are normally distributed -
Alternative hypothesis for Shapiro-Wilk test: the data are not normally distributed. The figure
representing the result of Shapiro-Wilk normality test is shown below:
From the result of the Shapiro-Wilk test I observed that the p value for pulse rate for Gender is
less than 0.05 so I reject the null hypothesis that data are normally distributed and accept the
alternative hypothesis that data are not normally distributed.
Since the p value for the pulse rate for Female is greater than 0.05 so I accpet the null
hypothesis and reached to the conclusion that the pulse rate for female is normally distributed.
Equality of Variance
I performed F-test to assess the equality of variance. The null hypothesis for F-test is there is no
significant difference between the variance of two sets of data. While the alternative
hypothesis is that there is a significant difference between the variance of two sets of data.
From the above figure I observed that the p-value of F-test is p = 0.5404. It’s greater than the
significance level alpha = 0.05. In conclusion, there is no significant difference between the
variances of the two sets of data. Therefore, we can use the classic t-test witch assume equality
of the two variances.
T test
To state the difference in confidence interval of means I used two sample t-test. The result of t-
test is shown in below figure
From above figure it is evident that the difference in 95 percent confidence interval of
difference in mean is [-8.397663, 1.702748]
Question 4) Perform a suitable test to determine if the second pulse rate (Pulse2) differs
between those who ran or sat between the first and second pulse measurements (Ran). In your
analysis, examine Pulse2 across Ran with appropriate descriptive statistics and graphics. Assess
each sample for normality. Assess equality of variance. State the CI for the difference in means
and interpret these values.
Answer) The table representing the mean value of Pulse2 across students who ran and sat is
shown below:
Table 2: Mean Values of Pulse2 for students who ran and sat
I used box plot to represent the distribution of Pulse2 across students who ran and sat. The box
plot representing this information is shown below:
Fig 6 Box plot for Pulse2 distribution by students who ran and sat
From the above table and box plot it is pretty clear that there is a huge difference in the mean
value of Pulse2 rate as the mean value for students who ran is (126.847) is greater than mean
value of Pulse2 for student who sat which is (74.857). So the samples of Pulse2 for students
who ran and sat are independent.
Normality of Each Sample
I applied Shapiro-Wilk normality test for assessing the normality of pulse2 for students who sat
and ran. The Null hypothesis for Shapiro-Wilk test: the data are normally distributed -
Alternative hypothesis for Shapiro-Wilk test: the data are not normally distributed. The figure
representing the result of Shapiro-Wilk normality test is shown below:
From the result of the Shapiro-Wilk test I observed that the p value for pulse rate for student
who sat is less than 0.05 so I reject the null hypothesis that data are normally distributed and
accept the alternative hypothesis that data are not normally distributed.
Since the p value for the pulse2 rate for student who ran is greater than 0.05 so I accpet the null
hypothesis and reached to the conclusion that the pulse rate for student who ran is normally
distributed.
Equality of Variance
I performed F-test to assess the equality of variance. The null hypothesis for F-test is there is no
significant difference between the variance of two sets of data. While the alternative
hypothesis is that there is a significant difference between the variance of two sets of data.
From the above figure I observed that the p-value of F-test is p = 2.198e-09. It’s less than the
significance level alpha = 0.05, so I reject the null hypothesis. In conclusion, there is a significant
difference between the variances of the two sets of data
T test
To state the difference in confidence interval of means I used two sample t-test. The result of t-
test is shown in below figure
From above figure it is evident that the difference in mean for 95 percent confidence interval of
difference is [44.07839, 59.90298]