Task A Sharma Sonali Malahat Dianat A. Dependence of THC concentration in blood on the amount of cannabis smoked was analyzed in one person who smoked different amounts of dried cannabis of the same source. The intervals between measurements were long enough to decrease of THC concentration to 0 before each trial. Does THC concentration depend on the amount of cannabis smoked? Perform a statistical analysis and illustrate it with a figure. Code smoke<-data.frame(THC=c(10.1,3,8.7,12.3,20.8,5.9,10.1,12.3,5.9,10.1), cannabis=c(5.3,1.2,3.8,8.5,9.1,3.1,4.5,8.5,6.5,7.8)) summary(smoke) lm.1<-lm(THC~cannabis, data=smoke) summary(lm.1) plot(lm.1) lm(formula = THC ~ cannabis, data = smoke) Residuals: Min 1Q Median 3Q Max -4.9687 -1.4006 -0.2593 1.4734 6.2498 Coefficients: Estimate Std. Error t value Pr(>|t|) (Intercept) 1.6650 2.5453 0.654 0.53138 cannabis 1.4160 0.4003 3.537 0.00765 ** --- Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 Residual standard error: 3.211 on 8 degrees of freedom Multiple R-squared: 0.6099, Adjusted R-squared: 0.5612 F-statistic: 12.51 on 1 and 8 DF, p-value: 0.007655 plot(THC~cannabis, data=smoke) abline(coef(lm.1)) pred<-predict(lm.1,newdata=data.frame(cannabis=seq(0,10,by=1)),se=T) pred$df summary(pred) lines(seq(0,10,by=1),pred$fit) lines(seq(0,10,by=1),pred$fit+pred$se.fit*qt(0.975,pred$df),lty=2) lines(seq(0,10,by=1),pred$fit+pred$se.fit*qt(0.025,pred$df),lty=2)