Aim:- To test the significant difference between population mean, when population variance is
unknown.

Problem 1:-
A random sample of 10 boys has the following IQ’s: 70, 120, 110, 101, 88, 83, 95, 98, 107, 100.
Do these data supports the assumption of population mean IQ of 100.

R Code:
> x=c(70,120,110,101,88,83,95,98,107,100)
>x
[1] 70 120 110 101 88 83 95 98 107 100
>t.test(x,mu=100)
One Sample t-test
data: x
t = -0.62034, df = 9, p-value = 0.5504
Alternative hypothesis: true mean is not equal to 100
95 percent confidence interval:
86.98934
107.41066
sample estimates:
mean of x
97.2
>qt(0.975,9)
[1] 2.262157

Problem 2 :-
An outbreak of salmonella-related illness was attributed to ice produced at a certain factory.
Scientists measured the level of Salmonella in 9 randomly sampled batches ice crean.Thelevels(in
MPN/g) were:
0.593     0.142    0.329    0.691    0.231    0.793    0.519    0.392    0.418
Is there evidence that the mean level pf Salmonella in ice cream greater than 0.3
MPN/g?

R - Code:-
> x=c(0.593,0.142,0.329,0.691,0.231,0.793,0.519,0.392,0.418)
>x
[1] 0.593 0.142 0.329 0.691 0.231 0.793 0.519 0.392 0.418
>t.test(x,alternative="greater",mu=0.3)
One Sample t-test
data: x
t = 2.2051, df = 8, p-value = 0.02927
alternative hypothesis: true mean is greater than 0.3
95 percent confidence interval:
0.3245133 Inf
sample estimates:
mean of x
0.4564444
>qt(0.95,9)
[1] 1.833113