实验设计与分析(第6版,Montgomery)第3章单因子实验:方差分析3.11思考题3.6 R语言解题

本文是实验设计与分析(第6版,Montgomery著,傅珏生译) 第3章单因子实验:方差分析3.11思考题3.6 R语言解题。主要涉及单因子方差分析,正态性假设检验,残差与拟合值的关系图,TukeyHSD法。

(a) Is there evidence to indicate that dosage level affects bioactivity? Use α = 0.05.

X<-c(24,28,37,30,37,44,31,35,42,47,52,38)

A<-factor(rep(1:3, each=4))

miscellany<-data.frame(X,A)

aov.mis<-aov(X~A, data=miscellany)

> summary(aov.mis) Df Sum Sq Mean Sq F value Pr(>F)

A 2 450.7 225.33 7.036 0.0145 *

Residuals 9 288.2 32.03


Signif. codes:

0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1

There appears to be a different in the dosages.

(b) If it is appropriate to do so, make comparisons between the pairs of means. What conclusions can you draw?

> TukeyHSD(aov.mis)

Tukey multiple comparisons of means

95% family-wise confidence level

Fit: aov(formula = X ~ A, data = miscellany)

$A

diff lwr upr p adj

2-1 7 -4.172869 18.17287 0.2402975

3-1 15 3.827131 26.17287 0.0114434

3-2 8 -3.172869 19.17287 0.1680265

Because there appears to be a difference in the dosages, the comparison of means is appropriate.

opar <- par(mfrow=c(2,2),cex=.8)

plot(aov.mis)

par(opar)

相关推荐
梦想的初衷~2 天前
MaxEnt物种分布建模完整教程|理论基础、数据获取、R清洗优化与论文制图全流程
r语言·生态遥感·物种分布模拟·maxent建模·r语言数据分析·arcgis实操·科研建模
Omics Pro6 天前
~30,000+引用!理论2005,R包2008,多组学集成AI增强
开发语言·数据库·人工智能·算法·机器学习·自然语言处理·r语言
天桥下的卖艺者8 天前
chrals.CTI函数升级版发布,增加了CTI衍生的脂肪指数提取
数据库·r语言
小师兄吃牛肉9 天前
什么是R语言?如何快速学习R语言
开发语言·学习·r语言
喆星时瑜9 天前
Win10/11 安装 R 与 RStudio 详细图文教程
开发语言·r语言·安装
喆星时瑜10 天前
R语言基础语法入门
开发语言·r语言
喆星时瑜10 天前
R语言向量语法的详细教程
开发语言·r语言
临床数据科学和人工智能兴趣组12 天前
在R语言中, 使用 as.factor() 函数转换数值型变量
开发语言·r语言
babe小鑫22 天前
信息与计算科学专业应届生面试 怎么证明自己能解决业务问题
学习·r语言·excel
深兰科技23 天前
深兰科技受邀参与第二届中国(南宁)—东盟人工智能场景应用对接会,深化AI国际合作
人工智能·qt·r语言·scala·symfony·智能机器人·深兰科技