Question

In: Math

Using Rcode solve A company with a large fleet of cars wants to study the gasoline...

Using Rcode solve

A company with a large fleet of cars wants to study the gasoline usage. They check the gasoline usage for 50 company trips chosen at random, finding a mean of 25.02 mpg and sample standard deviation is 4.83 mpg.

a. Which kind of confidence interval is appropriate to use here, z-interval or t-interval?

b. What are the assumptions to check for the interval you chose?

c. Please use R to find the critical value the company needs when constructing a (two-sided) 98% CI.

d. Please use R to construct a (two-sided) 98% CI for the mean of the general gasoline usage.

e. Please use R to construct a 98% upper confidence bound for the mean of the general gasoline usage.

f. Create a R function whose argument is the width of CI, and the output is the sample size necessary to achieve such accuracy. The confidence level is fixed at 98%.

g. Apply the function you created in part (f) to demonstrate that larger sample size is required to achieve better accuracy (i.e, narrower CI width). Confidence level is fixed at 98%. Show at least three examples

Solutions

Expert Solution

Given,

a) We will use z- interval, why, is in the next part.

b) Since, sample size is large (n>30), so, we could preferably use z- interval

Assumptions are:

c).

Confidence level = 98%

Critical value for two sided test is,

qnorm(1-0.02/2) ### this will give

2.326348

For two sided test we have

d).

To construct 98% confidence interval, we develop a function in R,

confint=function(xbar,s,n){
xbar=25.02
s=4.83
n=50
moe=2.33*s/sqrt(n) ### moe is margin of error
Llimit=xbar-moe
Ulimit=xbar+moe
int=c(Llimit,Ulimit)
return(int)
}
confint(xbar,s,n)
23.42846 26.61154

Hence, the inerval is (23.42846 , 26.61154)

e)

For upper bound mean for right tailed test (or one sided test),

confint=function(xbar,s,n){
xbar=25.02
s=4.83
n=50
moe=2.05*s/sqrt(n) ### moe is margin of error
Llimit=xbar-moe
Ulimit=xbar+moe
int=c(Llimit,Ulimit)
return(int)
}
confint(xbar,s,n)
23.61972 26.42028

Hence, the interval is (23.61972 , 26.42028)

  • The first assumption is that our sample is a simple random sample and this information is usually provided in the problem.
  • Our sampling distribution is normally distributed


Related Solutions

Using Rcode solve A company with a large fleet of cars wants to study the gasoline...
Using Rcode solve A company with a large fleet of cars wants to study the gasoline usage. They check the gasoline usage for 50 company trips chosen at random, finding a mean of 25.02 mpg and sample standard deviation is 4.83 mpg. a. Which kind of confidence interval is appropriate to use here, z-interval or t-interval? b. What are the assumptions to check for the interval you chose? c. Please use R to find the critical value the company needs...
A company with a large fleet of cars hopes to keep gasoline costs down and sets...
A company with a large fleet of cars hopes to keep gasoline costs down and sets a goal of attaining a fleet average of at least 2424 miles per gallon. To see if the goal is being​ met, they check the gasoline usage for 5050 company trips chosen at​ random, finding a mean of 22.0522.05 mpg and a standard deviation of 5.555.55 mpg. Is this strong evidence they have failed to attain their fuel economy​ goal? Complete parts a through...
A company with a large fleet of cars sets a goal of attaining a fleet average...
A company with a large fleet of cars sets a goal of attaining a fleet average of at least 26 miles per gallon of gasoline. To see if that goal is being met, they check the gasoline usage for 50 company trips chosen at random, finding a mean of 25.02 mpg and a standard deviation of 4.83 mpg. a) Is this a strong evidence that they have failed to attain their fuel economy goal? Assume significance level of 0.1. b)...
A city in Ohio is considering replacing its fleet of gasoline powered cars with electric cars....
A city in Ohio is considering replacing its fleet of gasoline powered cars with electric cars. The manufacturer of the electric cars claims that this municipality will experience significant cost savings over the life of the fleet if it chooses to pursue this conversion. If the manufacturer is correct, the city will save about $1.5 million. If the new technology employed within the electric cars is faulty as some critics suggest, it will cost the city $675,000. A third possibility...
3. The owner of a gasoline station wants to study gasoline purchasing habits by motorists at...
3. The owner of a gasoline station wants to study gasoline purchasing habits by motorists at his station. He selects a random sample of 55 motorists during a certain week, with the following results: The amount purchased was XBar = 11.0 gallons, S = 3.3 gallons. 15 motorists purchased premium-grade gasoline. At the 0.05 level of significance, is there evidence that the population mean purchase was different from 10 gallons? At the 0.1O level of significance, is there evidence that...
1. A company with a fleet of 1500 cars found that the emissions systems of 17...
1. A company with a fleet of 1500 cars found that the emissions systems of 17 out of the 53 randomly selected cars from their fleet failed to meet pollution control guidelines. If a significant number of vehicles are found to be out of compliance, the whole fleet will need to be inspected and brought up to current regulations. Is there strong evidence that more than 20% of the fleet might be out of compliance? Use a 1% level of...
Your company is considering the purchase of a fleet of cars for $200,000. It can borrow...
Your company is considering the purchase of a fleet of cars for $200,000. It can borrow at 6%. The cars will be used for four years. At the end of four years they will be worthless. You call a leasing agent and find that the cars can be leased for $55,000 per year. The corporate tax rate is 34% and the cars belong in CCA class 10 (a 30% class), what is the net advantage to leasing? a. $1,802 b....
Your company is considering the purchase of a fleet of cars for $200,000. It can borrow...
Your company is considering the purchase of a fleet of cars for $200,000. It can borrow at 6%. The cars will be used for four years. At the end of four years, they will be worthless. You call a leasing agent and find that the cars can be leased for $55,000 per year. The corporate tax rate is 34% and the cars belong in CCA class 10 (a 30% class), what is the net advantage to leasing? Select one: a....
Your company is considering the purchase of a fleet of cars for $195,000. It can borrow...
Your company is considering the purchase of a fleet of cars for $195,000. It can borrow at 8.5%. The cars will be used for four years. At the end of four years they will be worthless. You call a leasing agent and find that the cars can be leased for $55,000 per year. The corporate tax rate is 34% and the cars belong in CCA class 10 (a 30% class), what is the net advantage to leasing? A) $6,594 B)...
The owner of a gas station wants to study gasoline purchasing habits of motorists at this...
The owner of a gas station wants to study gasoline purchasing habits of motorists at this station. He selects a random sample of 60 motorists during a certain week, with the following results: The amount of gas purchased was; mean = 11.3 gallons, standard deviation = 3.1 gallons; Eleven motorists purchased premium-grade gasoline (4 points) At the 0.05 significance level, is there evidence that the population mean purchase was different from 10 gallons? (1 point) Determine the p-value in part...
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT