Consider the SLR y = 50 + 10x + e where e is NID(0.16). n = 20 pairs of observations. Generate 500 samples of 20 obersvations drawing 1 observations drawing one observation from each level of x = .5,1,1.5 ... 10 for each sample
A) For each sample computer the least squares regression estimates of the slop and intercept. Construct histograms of the sample values of B_0_hat and B_1_hat. B) For each sample compute an estimate of E(y|x=5) Construct a histogram from these estimates. C) For each sample compute a 95% CI on the slope. How manyt of these contain the true value B_1 = 10 D) For each estimate of E(y|x=5) in part b compute the 95% CI. How many of these intervals contain the trye value of E(y|x=5)=100? I have 0 idea how to do these as R was not a prereq for my regression course but is needed for these problems. As much help as you could offer would be amazing. -- View this message in context: http://n4.nabble.com/SLR-500-Random-Samples-tp1555769p1555769.html Sent from the R help mailing list archive at Nabble.com. ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.