111k views
2 votes
Analysis of the oil data set. One project from Fall 1999 consisted of heating motor oil until it catches on fire. There were eight runs in random order where "conv" stands for conventional oil, "syn" stands for synthetic oil, "5/30" and "20/50" are two viscosities, and "time" is the time until catching fire. The data are as follows

Obs type vis time 1 conv 5/30 345 2 syn 5/30 658 3 conv 20/50 360 4 syn 20/50 546 5 conv 5/30 360 6 syn 5/30 676 7 conv 20/50 342 8 syn 20/50 512
Run lm in Splus or M-Lab to get the ANOVA output for determining (use full model: model time=vis+type+vis*type, after class vis type)if there is mean difference in oil types (conv vs. syn): p value =

User Mscccc
by
4.1k points

1 Answer

3 votes

Answer:

See the explanation for the answer

Explanation:

We shall analyse this in the open source statisitcal packageR , the complete R snippet is as follows

# read the data into R dataframe

data.df<- read.csv("C:\\Users\\586645\\Downloads\\Chegg\\syn.csv",header=TRUE)

str(data.df)

# perform anova analysis

a<- aov(lm(time~type*vis,data=data.df))

#summarise the results

summary(a)

colr<-c("salmon3" , "plum2","coral1","palegreen1" ,"orangered" ,"magenta4" )

# plots

boxplot(time~type*vis, data=data.df,ylab="Values",

main="Boxplots of the Data",col=colr,horizontal=TRUE)

attach(data.df)

interaction.plot(type,vis,time, type="b", col=c(2:6),

leg.bty="o", leg.bg="beige", lwd=2, pch=c(18,24,22),

xlab="Type",

ylab="Value",

main="Interaction Plot")

The results are

> summary(a)

Df Sum Sq Mean Sq F value Pr(>F)

type 1 121278 121278 478.18 2.59e-05 *** ### signficant as the p value is less than 0.05

vis 1 9730 9730 38.36 0.00345 ** ### signficant as the p value is less than 0.05

type:vis 1 9316 9316 36.73 0.00374 ** ### signficant as the p value is less than 0.05 , hence the interaction effect is significant . The p values are highlighted

Residuals 4 1015 254

---

Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1

User Tolgayilmaz
by
3.4k points