Download 6/25/97 502as1

Survey
yes no Was this document useful for you?
   Thank you for your participation!

* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project

Document related concepts

Degrees of freedom (statistics) wikipedia , lookup

History of statistics wikipedia , lookup

Bootstrapping (statistics) wikipedia , lookup

Confidence interval wikipedia , lookup

Student's t-test wikipedia , lookup

Time series wikipedia , lookup

Misuse of statistics wikipedia , lookup

Transcript
252solngr1 2/05/04
(Open this document in 'Page Layout' view!)
Graded Assignment 1
Please show your work! Neatness and whether the papers are stapled may affect your grade.
1. A manufacturer is concerned that a machine is not adequately filling a 200 oz container. 15
measurements are taken. Results are below.
198
204
189
182
205
195
188
201
200
203
201
193
194
196
190
Compute the sample standard deviation using the computational formula. Use this sample standard
deviation to compute a 90% confidence interval for the mean. Does the mean differ significantly from 200
oz? Why?
2. How would your results change if the sample of 15 had been taken from a population of 100?
3. Assume that the population standard deviation is 7.00 (and that the sample of 15 is taken from a very
large population). Find z .04 and use it to compute a 92% confidence interval. Does the mean differ
significantly from 200 oz? Why?
Solution:
1)
index x
 x  2939 ,  x  576471 ,
 x  2939  195.9333
x
x2
2
1 198 39204
2 204 41616
3 189 35721
4 182 33124
5 205 42025
6 195 38025
7 188 35344
8 201 40401
9 200 40000
10 203 41209
11 201 40401
12 193 37249
13 194 37636
14 196 38416
15 190 36100
sum 2939 576471
sx 
sx
n

n
15
 x  nx 2
2
s x2 
n 1
n  15
576471  15195.9333
14
2

623.12928
 44.5093
14
s x  44.5093  6.67152 .

s x2
44.5993

 2.9673  1.7226
n
15
The formula is in table 20 of the Supplement.
  .10

2
 .05
Confidence interval:
14 
tn2 1  t.05
 1.761
  x  tn1 s x
is the formula for a two sided interval.
2
  x  tn1 s x  195.9333  1.7611.7227  195.9333  3.0337
2
we ask if the mean is significantly different from 200, our null hypothesis is
or 192.900 to 198.967. If
H 0 :   200 and since 200
is not between the top and the bottom of the confidence interval, reject H 0 and say that the mean is
significantly different from 200.
If we ask if the mean is significantly different from 198, the null hypothesis is H 0 :   198 and 198 is
between the top and the bottom of the confidence interval. So we reject H 0 or we can say that the mean is
significantly different from 198.
252solngr1 2/05/04
(Open this document in 'Page Layout' view!)
N  100 , the sample of 15 is more than 5% of the population, so use
s
N n
100  15
sx  x
 1.7226
 1.7226 0.8586  1.72260.92660  1.5962 .
100  1
n N 1
n 1
14 
Recall that x  195.9333 ,   .10 ,  2  .05 and t 
 t.05
 1.761 .
2
2) If
Confidence interval:
  x  tn1 s x
is the formula for a two sided interval.
2
  x  tn1 s x  195.9333  1.7611.5962  195.9333  2.8109
2
or 193.122 to 198.744. The
interval is smaller, but it doesn’t change anything – the mean is still significantly different from 200 but not
198.
3) a) Find
z.04 . Please don’t tell me that because P0  z  0.04  .0160 , that z.04 is .0160.
Make a diagram! The diagram for z will be a Normal curve centered at zero and will show one point,
z.04 , which has 4% above it (and 96% below it!) and is above zero because zero has 50% below it. Since
zero has 50% above it, the diagram will show 46% between zero and
z.04 .
z.04 so that Pz  z.04   .04 or P0  z  z.04   .4600 .
From the interior of the Normal table the closest we can come to .4600 is P0  z  1.75  .4599 . This
means that z.04  1.75 .
Check: Pz  1.75  Pz  0  P0  z  1.75  .5  .4599  .0401  .04.
From the diagram, we want one point
Normal Curve with Mean 0 and Standard Deviation 1
The Area to the Right of 1.75 is 0.0401
0.4
Density
0.3
0.2
0.1
0.0
-5
b) We know that
-4
-3
-2
-1
0
Data A xis
1
x  195.9333 , n  15 and   7 . So  x 
2

n

3
7

15
=1.8074. The 92% confidence interval has 1    .92 or   .08 , so z  z.04
2
4
72
 3.2667
15
 1.75 . The
confidence interval is   x  z  x
2
 195.9333  1.751.8074  195.93  3.16 or 192.77 to
199.09. If we test the null hypothesis
H 0 :   200 against the alternative hypothesis H 0 :   200 ,
since 200 is not on the confidence interval, we reject the null hypothesis. The result is not significantly
different from 198 because 198 is within the interval.
Extra Credit:
4) a. Use the data above to compute a 90% confidence interval for the population standard deviation.
252solngr1 2/05/04
(Open this document in 'Page Layout' view!)
n  1s 2
Solution: From the supplement pg 1,

2
2 
s x  6.67152 , n  15 ,   .10 and
2
2 
1
2

n  1s 2
 .05 . We use 
n 1
 21   .9514  6.5706 . The formula becomes
. We know s x  44.5093 ,
2
2
2  n 1

2
14 
  .05
 23.6848 and
1444.5093   2  1444.5093
23.6848
6.5706
2
26.3083    94.8361. If we take square roots, we get 5.129    9.738
2
or
b. Assume that you got the sample standard deviation that you got above from a sample of 45, repeat a.
Solution: From the supplement pg 2,
s 2 DF
s 2 DF
. We now have

z   2 DF
 z   2 DF
s x  6.67152 , n  45 ,   .10 and
2

2
2  .05 . We use z.05  1.645 and
2DF  2(44)  88  9.3808 . The formula becomes
6.671529.3808    6.671529.3808 or
5.681    8.090 .
1.645  9.3808
 1.645  9.3808
c. Fool around with the method for getting a confidence interval for a median and try to come close to a
90% confidence interval for the median.
The numbers in order are
x1
x 2 x3
x 4 x5
x6
x7
x8 x 9 x10 x11 x12 x13 x14 x15
182 188 189 190 193 194 195 196 198 200 201 201 203 204 205
It says on the outline that   2Px  k  1 . If we check a Binomial table with
n  15 and p  .50 , we
find that the first quantity below 5% is Px  3  .01758 . So if k  4 , k  1  3 and
  2.01758  .03516 and P190    201  1  .03516  96.48% . If you are willing to live
dangerously use k  5 , k  1  4 ,   2.05923  .11846 and P193    201
 1 .11846  88.15% . If we use the formula k 
n  1  z . 2 n
2

15  1  1.645 15
 4.81 ,
2
it tells us to use the 4th number from the end, since, if we want to be conservative we round the answer
down.
How I got these results
‘MTB >’ is the Minitab prompt. The retrieval is done using the ‘file’ pull-down menu and the ‘open worksheet’ command followed
by finding where I put the data. Other instructions were typed in the ‘session’ window.
I put the data in column 1 in Minitab and used the ‘Gsummary’ command to get the mean and standard
deviation.
————— 2/3/2005 8:31:48 PM ————————————————————
Welcome to Minitab, press F1 for help
Results for: 2gr1-051.MTW
MTB > GSummary c1;
SUBC>
Confidence 90.0.
Summary for C1
252solngr1 2/05/04
(Open this document in 'Page Layout' view!)
Summary for C1
A nderson-Darling N ormality Test
184
188
192
196
200
A -S quared
P -V alue
0.23
0.763
M ean
S tDev
V ariance
S kew ness
Kurtosis
N
195.93
6.67
44.50
-0.505497
-0.417569
15
M inimum
1st Q uartile
M edian
3rd Q uartile
M aximum
204
182.00
190.00
196.00
201.00
205.00
90% C onfidence Interv al for M ean
192.90
198.97
90% C onfidence Interv al for M edian
192.72
201.00
90% C onfidence Interv al for S tD ev
9 0 % C onfidence Inter vals
5.13
9.74
Mean
Median
192
194
MTB > let c2=c1*c1
MTB > Print c1 c2
196
198
200
202
I computed the square of C2 in c1 and got the sums for computing the variance.
Data Display
Row
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
C1
198
204
189
182
205
195
188
201
200
203
201
193
194
196
190
C2
39204
41616
35721
33124
42025
38025
35344
40401
40000
41209
40401
37249
37636
38416
36100
MTB > sum c1
Sum of C1
Sum of C1 = 2939
MTB > sum c2
Sum of C2
Sum of C2 = 576471
MTB > describe c1
Descriptive Statistics: C1
Variable
N
N*
Mean
SE Mean
StDev
Minimum
Q1
Median
Q3
252solngr1 2/05/04
C1
Variable
C1
(Open this document in 'Page Layout' view!)
15
0 195.93
Maximum
205.00
1.72
6.67
182.00
190.00
196.00
201.00
MTB > Onet c1;
This does a 90% confidence interval and a test for a mean of 200 using s.
SUBC>
Test 200;
SUBC>
Confidence 90.
One-Sample T: C1
Test of mu = 200 vs not = 200
Variable
N
Mean StDev SE Mean
C1
15 195.933 6.670
1.722
90% CI
(192.900, 198.967)
T
-2.36
P
0.033
MTB > OneZ c1;
This does a 92% confidence interval and a test for a mean of 200 using sigma.
SUBC>
Sigma 7;
SUBC>
Test 200;
SUBC>
Confidence 92.
One-Sample Z: C1
Test of mu = 200 vs not = 200
The assumed standard deviation = 7
Variable
N
Mean StDev SE Mean
C1
15 195.933 6.670
1.807
92% CI
(192.769, 199.098)
Z
-2.25
P
0.024
MTB > %normarea5a This does the graph shown above.
Executing from file: normarea5a.MAC
Graphic display of normal curve areas
Finds and displays areas to the left or right of a given value
or between two values. (This macro uses C100-C116 and K100-K116)
Enter the mean and standard deviation of the normal curve.
DATA> 0
DATA> 1
Do you want the area to the left of a value? (Y or N)
n
Do you want the area to the right of a value? (Y or N)
y
Enter the value for which you want the area to the right.
DATA> 1.75
...working...
Normal Curve Area
MTB > let c5=c1
MTB > Sort c5 c5;
SUBC>
By c5.
MTB > print c5
This sorts c1, which I moved to c5.
Data Display
C5
182
204
188
205
189
190
193
194
195
196
198
200
201
201
203
Extra Credit:
5. Check some numbers in the t, Chi-Squared or F tables using the new set of Minitab routines that I have
prepared. To use the new set of routines, set up a file to hold your work. Then go to
http://courses.wcupa.edu/rbove , open the Minitab folder and download any of the following:
Normal Distribution Area programs:
NormArea5A.txt
252solngr1 2/05/04
(Open this document in 'Page Layout' view!)
or NormArea5C.txt and NormArea5.txt.
t Distribution Area programs:
tAreaA.txt
or tAreaC.txt and tArea.txt
Chi-squared Distribution Area programs:
ChiAreaA.txt
or ChiAreaC.txt and ChiArea.txt
F Distribution area programs:
FAreaA.txt
or FAreaC.txt and FArea.txt
Use Notepad (under ‘tools’ in Minitab’) to convert their extensions from .txt back to .mac. To see how they
are used, look at http://courses.wcupa.edu/rbove/Minitab/Area.doc.
Routines like tAreaA are self prompting. To use routines like tAreaC, you need to set up your data in
advance. If you want to use one of the worksheets that are mentioned in
http://courses.wcupa.edu/rbove/Minitab/Area.doc, click on ‘File’ and then ‘Open Worksheet.’ Copy a URL
like the ones below into File Name.’
http://courses.wcupa.edu/rbove/Minitab/252PrA1d-f.MTW
http://courses.wcupa.edu/rbove/Minitab/tEx1.MTW
http://courses.wcupa.edu/rbove/Minitab/ChiEx1.MTW
http://courses.wcupa.edu/rbove/Minitab/FEx1.MTW
10 
Results: I looked at the tables and found t .10  1.372 ,
10
 2 .90  4.8650 , F.1010,10  2.32
and
10,10
F.90
1
10
z.10  1.282 ,  2 .10  23.2093 ,
2.32
 0.431 . For the numbers with .10 as a
subscript, I checked that the probability above them was .10, for the numbers with .90 as a subscript, I
checked that the probability below them was .10.
MTB > %tareaA
Executing from file: tareaA.MAC
Graphic display of t curve areas
Finds and displays areas to the left or right of a given value
or between two values. (This macro uses C100-C116 and K100-K120)
Enter the degrees of freedom.
DATA> 10
Do you want the area to the left of a value? (Y or N)
n
Do you want the area to the right of a value? (Y or N)
y
Enter the value for which you want the area to the right.
DATA> 1.372
...working...
t Curve Area
252solngr1 2/05/04
(Open this document in 'Page Layout' view!)
t Curve with 10 Degrees of Freedom and Standard Deviation 1.11803
The Area to the Right of 1.372 is 0.1000
0.4
Density
0.3
0.2
0.1
0.0
-5.0
-2.5
0.0
Data A xis
2.5
5.0
Data Display
mode
median
0
0
MTB > %normarea5a
Executing from file: normarea5a.MAC
Graphic display of normal curve areas
Finds and displays areas to the left or right of a given value
or between two values. (This macro uses C100-C116 and K100-K116)
Enter the mean and standard deviation of the normal curve.
DATA> 0
DATA> 1
Do you want the area to the left of a value? (Y or N)
n
Do you want the area to the right of a value? (Y or N)
y
Enter the value for which you want the area to the right.
DATA> 1.282
...working...
Normal Curve Area
Normal Curve with Mean 0 and Standard Deviation 1
The Area to the Right of 1.282 is 0.0999
0.4
Density
0.3
0.2
0.1
0.0
-5
-4
-3
-2
-1
0
Data A xis
1
2
3
4
252solngr1 2/05/04
(Open this document in 'Page Layout' view!)
MTB > %ChiareaA
Executing from file: ChiareaA.MAC
Graphic display of chi square curve areas
Finds and displays areas to the left or right of a given value
or between two values. (This macro uses C100-C116 and K100-K120)
Enter the degrees of freedom.
DATA> 10
Do you want the area to the left of a value? (Y or N)
n
Do you want the area to the right of a value? (Y or N)
y
Enter the value for which you want the area to the right.
DATA> 1.282
...working...
ChiSquare Curve Area
ChiSquare Curve with 10 Degrees of Freedom and Standard Deviation 4.47214
The Area to the Right of 1.282 is 0.9995
0.10
Density
0.08
0.06
0.04
0.02
0.00
0
10
20
Data A xis
30
Data Display
mode
median
8.00000
9.33333
MTB > %chiareaA
Executing from file: chiareaA.MAC
Graphic display of chi square curve areas
Finds and displays areas to the left or right of a given value
or between two values. (This macro uses C100-C116 and K100-K120)
Enter the degrees of freedom.
DATA> 10
Do you want the area to the left of a value? (Y or N)
y
Enter the value for which you want the area to the left.
DATA> 4.8650
...working...
Chi Squared Curve Area
40
252solngr1 2/05/04
(Open this document in 'Page Layout' view!)
ChiSquare Curve with 10 Degrees of Freedom and Standard Deviation 4.47214
The Area to the Left of 4.865 is 0.1000
0.10
Density
0.08
0.06
0.04
0.02
0.00
0
10
20
Data A xis
30
40
Data Display
mode
median
8.00000
9.33333
MTB > %fareaA
Executing from file: fareaA.MAC
Graphic display of F curve areas
Finds and displays areas to the left or right of a given value
or between two values. (This macro uses C100-C116 and K100-K120)
Enter the degrees of freedom.DF2 must be above 4.
DATA> 10
DATA> 10
Do you want the area to the left of a value? (Y or N)
n
Do you want the area to the right of a value? (Y or N)
y
Enter the value for which you want the area to the right.
DATA> 2.32
...working...
F Curve Area
F Curve with numerator DF of 10 and Denominator DF of 10
The Area to the Right of 2.32 is 0.1003
0.8
0.7
Density
0.6
0.5
0.4
0.3
0.2
0.1
0.0
0
Data Display
mode
0.818182
2
4
6
8
Data A xis
10
12
14
16
252solngr1 2/05/04
(Open this document in 'Page Layout' view!)
Data Display
std dev
0.968246
MTB > %fareaA
Executing from file: fareaA.MAC
Graphic display of F curve areas
Finds and displays areas to the left or right of a given value
or between two values. (This macro uses C100-C116 and K100-K120)
Enter the degrees of freedom.DF2 must be above 4.
DATA> 10
DATA> 10
Do you want the area to the left of a value? (Y or N)
y
Enter the value for which you want the area to the left.
DATA> .431
...working...
F Curve Area
F Curve with Numerator DF of 10 Denominator DF of 10
The Area to the Left of 0.431 is 0.1003
0.8
0.7
Density
0.6
0.5
0.4
0.3
0.2
0.1
0.0
0
Data Display
mode
0.818182
Data Display
std dev
0.968246
2
4
6
8
Data A xis
10
12
14
16