1、第十一章:连续变量的统计推断(一)-T 检验练习一,样本均数与总体均数的比较从一批木头里抽取 5 根,测得直径如下,是否认为这批木头的平均直径是12.3cmOne-Sample StatisticsN Mean Std. Deviation Std. Error Mean直径 5 12.460 .2881 .1288One-Sample TestTest Value = 12.3 95% Confidence Interval of the Differencet df Sig. (2-tailed) Mean Difference Lower Upper直径 1.242 4 .282 .16
2、00 -.198 .518由上表知总体均数为12.3,T=1.242 ,P值为0.282可知,由于P值元大于检验水平0.05,因此不拒绝H 0,还不能认为样本所在的均数与假设的总体均数不同,即可认为这批木头的直径为12.3.。二,成组设计两样本均数的比较如比较两电子器材的电阻,随机出去的样本测量电阻,是比较两电子器材的电阻是否相同。A批 0.140 0.138 0.143 0.142 0.144 0.148 0.137B批 0.135 0.140 0.142 0.136 0.138 0.140 0.141Group Statistics批类 N Mean Std. Deviation Std.
3、 Error MeanA批 7 .14171 .003773 .001426电阻B批 7 .13886 .002610 .000986直径 12.3 12.8 12.4 12.1 12.7Idependent Samples TestLevenes Test for Equality of VariancesF Sig.电阻 .652568 .435I Idependent Samples Testt-test for Equality of MeanSig Mean Std.errorT df (2-tailed) Difference Difference 电阻 Equal varianc
4、es assumed 1.648 12 .125 0.002857 0.001734Equal variances not assumed 1.648 10.671 10.671 0.002857 0.001734由上表知:t=1.648 ,v=12,P=0.125.则P0.05, 故接受H 0, 认为两者的电阻值是相同的三,适应条件与方差齐性检验批类Case Processing SummaryCasesValid Missing Total批类 N Percent N Percent N PercentA批 7 100.0% 0 .0% 7 100.0%电阻B批 7 100.0% 0 .0
5、% 7 100.0%Descriptives批类 Statistic Std. ErrorMean .14171 .001426Lower Bound .1382295% Confidence Interval for Mean Upper Bound .145205% Trimmed Mean .14163Median .14200电阻 A批Variance .000Std. Deviation .003773Minimum .137Maximum .148Range .011Interquartile Range .006Skewness .440 .794Kurtosis -.142 1
6、.587Mean .13886 .000986Lower Bound .1364495% Confidence Interval for Mean Upper Bound .141275% Trimmed Mean .13890Median .14000Variance .000Std. Deviation .002610Minimum .135Maximum .142Range .007Interquartile Range .005Skewness -.492 .794B批Kurtosis -1.268 1.587电阻Stem-and-Leaf Plots电阻 Stem-and-Leaf
7、Plot for批类= A批Frequency Stem & Leaf2.00 13 . 784.00 14 . 02341.00 14 . 8Stem width: .010Each leaf: 1 case(s)电阻 Stem-and-Leaf Plot for批类= B批Frequency Stem & Leaf.00 13 .3.00 13 . 5684.00 14 . 0012Stem width: .010Each leaf: 1 case(s)四 , 配对设计样本均数的比较如为研究女性服用某避孕新药后是否影响其血清总胆固醇,讲20名女性按年龄配成10对。每对中随机抽取一人服用新药
8、,另一人服用安慰剂。经过一定时间后,测得血清总胆固醇含量,问该新药是否影响女性血清总胆固醇?配对号1 2 3 4 5 6 7 8 9 10新药组4.4 5 5.8 4.6 4.9 4.8 6 5.9 4.3 5.1安慰剂组6.2 5.2 5.5 5 4.4 5.4 5 6.4 5.8 6.2Paired Samples StatisticsMean N Std. Deviation Std. Error Mean新药组 5.080 10 .6197 .1960Pair 1安慰剂组 5.510 10 .6402 .2025Paired Samples CorrelationsN Correlat
9、ion Sig.Pair 1 新药组 & 安慰剂组 10 .020 .956Paired Samples TestPaired Differences95% Confidence Interval of the DifferenceMeanStd. DeviationStd. Error Mean Lower Upper t df Sig. (2-tailed)Pair 1 新药组 - 安慰剂组-.4300 .8820 .2789 -1.0609 .2009 -1.542 9 .158由上表知 P=0.158,故可以认为该新药影响女性总胆固醇由于样本中新药组与安慰剂组的差值为正数,因此该新药对女性的总胆固醇有影响。