Question

In: Math

Each of the distributions below could be used to model the time spent studying for an...

Each of the distributions below could be used to model the time spent studying for an exam. Take 1,000 random samples of size 25 from each of the distributions below. In each case (a,b,c), plot the empirical distribution of the sample mean, estimate the mean of the sample mean, and estimate the standard deviation of the sample mean. Compare the results to the theoretical results.

a. N(5, 1.52)

b. Unif(0,10)

c. Gamma(5,1)

Solutions

Expert Solution

Let be the mean of the population and be the standard deviation of the population. Using CLT (central limit theorem) we get that for a sample of size n,

  • the mean of the sample mean is
  • The standard deviation of the sample mean is

the sample size n=25

a) the population is . the normal distribution specification is

Hence the population mean and standard deviation are

  • the mean of the sample mean is
  • The standard deviation of the sample mean is

R code to simulate 1000 sample of size 25 (all statement starting with # are comments)

#set the random seed
set.seed(123)

#set the sample size
n<-25
#set the number of samples
r<-1000
#draw n*r samples from normal N(5,1.5^2)
x<-rnorm(n*r,mean=5,sd=1.5)
# convert x into a matrix of n rows and r columns
x<-matrix(x,nrow=n,ncol=r)
# get r sample means
xbar<-apply(x,2,mean)
# Get the mean of the sample mean
muxbar<-mean(xbar)
# get the standard deviation of the sample mean
sigmaxbar<-sd(xbar)
#plot the distribution of mean
hist(xbar,main="distribution of sample mean",freq=FALSE)
print(paste("Estimated mean of the sample mean is",round(muxbar,4)))
print(paste("Estimated standard deviation of the sample mean is",round(sigmaxbar,4)))

# get this output

b) the population is Uniform(0,10)

Given a uniform(a,b), the mean is and variance is

the population mean and variance are

  • the mean of the sample mean is
  • The standard deviation of the sample mean is

R code to simulate 1000 sample of size 25 (all statement starting with # are comments)

#set the random seed
set.seed(123)

#set the sample size
n<-25
#set the number of samples
r<-1000
#draw n*r samples from uniform(0,10)
x<-runif(n*r,0,10)
# convert x into a matrix of n rows and r columns
x<-matrix(x,nrow=n,ncol=r)
# get r sample means
xbar<-apply(x,2,mean)
# Get the mean of the sample mean
muxbar<-mean(xbar)
# get the standard deviation of the sample mean
sigmaxbar<-sd(xbar)
#plot the distribution of mean
hist(xbar,main="distribution of sample mean",freq=FALSE)
print(paste("Estimated mean of the sample mean is",round(muxbar,4)))
print(paste("Estimated standard deviation of the sample mean is",round(sigmaxbar,4)))

## get this output

c) the population is Gamma(5,1).

Given a , the mean is and variance is

Hence the population mean and variance are

  • the mean of the sample mean is
  • The standard deviation of the sample mean is

R code to simulate 1000 sample of size 25 (all statement starting with # are comments)

#set the random seed
set.seed(123)

#set the sample size
n<-25
#set the number of samples
r<-1000
#draw n*r samples from gamma(5,1)
x<-rgamma(n*r,shape=5,scale=1)
# convert x into a matrix of n rows and r columns
x<-matrix(x,nrow=n,ncol=r)
# get r sample means
xbar<-apply(x,2,mean)
# Get the mean of the sample mean
muxbar<-mean(xbar)
# get the standard deviation of the sample mean
sigmaxbar<-sd(xbar)
#plot the distribution of mean
hist(xbar,main="distribution of sample mean",freq=FALSE)
print(paste("Estimated mean of the sample mean is",round(muxbar,4)))
print(paste("Estimated standard deviation of the sample mean is",round(sigmaxbar,4)))

## get this


Related Solutions

Each of the distributions below could be used to model the time spent studying for an...
Each of the distributions below could be used to model the time spent studying for an exam. Take one random sample of size 25 from each of the distributions below. Then, take 1,000 resamples (i.e., sample with replacement) of size 25 from your sample. In each case (a,b,c), plot the empirical distribution of the sample mean, estimate the mean of the sample mean, and estimate the standard deviation of the sample mean. Compare the results to the theoretical results. a....
Using the data, fit an appropriate regression model to determine whether time spent studying (hours) is...
Using the data, fit an appropriate regression model to determine whether time spent studying (hours) is a useful predictor of the chance of passing the exam (result, 0=fail 1=pass). Formally assess the overall fit of the model. DATA three; INPUT result hours; /* result=0 is fail; result=1 is pass */ cards; 0 0.8 0 1.6 0 1.4 1 2.3 1 1.4 1 3.2 0 0.3 1 1.7 0 1.8 1 2.7 0 0.6 0 1.1 1 2.1 1 2.8 1...
A teacher is interested in the relationship between the time spent studying for an exam and...
A teacher is interested in the relationship between the time spent studying for an exam and exam score. The table lists scores for 5 students. The value of b0 = 67.91 and the value of b1 = 0.75 Hours studied 5 18 3 15 17 Exam score 63 87 79 72 82 . Step 4 of 6 : Calculate the Coefficient of Determination (R2). Round answer to four decimal places.
A researcher believes that there is a positive relationship between the time spent in studying and...
A researcher believes that there is a positive relationship between the time spent in studying and the score a student gets at the end of the semester. She selected a sample of students and recorded the following data: Time Spent in minutes Score out of 100 120 86 75 83 60 78 45 75 180 91 30 72 90 84 After analyzing the data using Microsoft Excel, the researcher got the outputs below: Answer the following (Please, use at least...
A multiple regression model is to be constructed to model the time spent using the internet...
A multiple regression model is to be constructed to model the time spent using the internet per week among internet users. The explanatory variables are age, hours spent working per week and annual income. Data has been collected on 30 randomly selected individuals: Time using internet (minutes) Age Hours working per week Annual income ('000) 140 56 39 28 257 35 31 79 163 35 35 34 115 33 52 27 182 45 36 37 214 51 57 80 187...
We spent a lot of time discussing and studying the impact of political hacking in elections....
We spent a lot of time discussing and studying the impact of political hacking in elections. What is being done to ensure that its impact does not impact the validity of the 2020 election? What preventions are in place? Being almost a month out from November 3rd election day, are we ready? Research this question and answer it .
In studying the relationship between average daily temperature and time spent on a telephone, suppose you...
In studying the relationship between average daily temperature and time spent on a telephone, suppose you computed r=0.607 using n=31 data points. Using the critical values table below, determine if the value of r is significant or not.
Homer is studying the relationship between the average daily temperature and time spent watching television and...
Homer is studying the relationship between the average daily temperature and time spent watching television and has collected the data shown in the table. The line of best fit for the data is yˆ=−0.6x+94.5. Assume the line of best fit is significant and there is a strong linear relationship between the variables. Temperature (Degrees) 40506070 Minutes Watching Television 70655952 (a) According to the line of best fit, what would be the predicted number of minutes spent watching television for an...
The normal distribution is a family of distributions that is often used to model business processes....
The normal distribution is a family of distributions that is often used to model business processes. Based on your readings for this module, give one example, different from those supplied in the overview, of how the normal distribution can be used in a working environment. This example may be from your own experience. Be sure to explain how the normal distribution is used in the example you provide. In responding to your peers, select responses that use a normal distribution...
A member of the Pareto family of distributions (often used in economics to model income distributions) has a distribution function given by
A member of the Pareto family of distributions (often used in economics to model income distributions) has a distribution function given byMath output errorF ( y ) = \left\{ \begin{array} { l l } { 0 , } & { y < \beta } \\ { 1 - \left( \frac { \beta } { y } \right) ^ { \alpha } , } & { y \geq \beta } \end{array} \right.F(y)={0,1−(yβ​)α,​y 0α,β>0. Find the density function.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT