udio Edit Code View Plots Session Build Debug Profile Tools Help Go to file/func
ID: 3349852 • Letter: U
Question
udio Edit Code View Plots Session Build Debug Profile Tools Help Go to file/function entral Limit Theorem 1.Rmd × 0'erEl que es) de la verdadera vuelta 01 Untitled#x "X lim.Rmd × #7his cod e generates nine other replicates for a sample size of n-l for a total of 10 replicates of sample size n-l 1 for (i in 1:9) 3 print(i) 34 round (runif(100 ,min=-3, max-17), digits-0) 5 m-100 6 n-20 37 x8-round (matrix(runi f (n*m,min·-3, max-17), nrow-m, ncol -n), digits 0) 8 x8 1) 28-r0wMeans (x8, na.rm- 1 z8 42 print (z8) 13 print (summary (z8)) 44print (mean(28)) 45 print (qqnorm(z8)) 46 print (qqline(z8)) 47 1ibrary (nortest) 48 print (ad.test (z8)) FALSE, dims ". 49 51 1:1 Discrete Uniform Distribution a sole Terminal R Markdown R Markdown tablerbindctable.ci-1.mean(z,ad. test())Explanation / Answer
library(nortest)
xx=c(); Nor=c();mm=c();
for ( i in 1:9){
m=100
n=20
x=round(matrix(runif(n*m,min=-3, max=17), nrow=m, ncol=n),digits=0)
z=rowMeans(x, na.rm=FALSE, dims=1)
mm[i]=mean(z)
nn=ad.test(z)
Nor[i]=nn$p.value
xx[i]=i
}
mt=cbind(xx,mm,Nor)
mt
xx mm Nor
[1,] 1 6.8335 0.814770969
[2,] 2 7.0895 0.051236025
[3,] 3 6.9455 0.181704220
[4,] 4 7.0355 0.568768018
[5,] 5 7.2095 0.007080558
[6,] 6 7.0515 0.625506771
[7,] 7 7.1450 0.924077922
[8,] 8 6.8660 0.010619300
[9,] 9 7.1955 0.132543294
Related Questions
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.