Question: Directions: All homework will be submitted electronically through email. You will be expected to turn in a word document with your answers to any questions,

 Directions: All homework will be submitted electronically through email. You will

Directions: All homework will be submitted electronically through email. You will be expected to turn in a word document with your answers to any questions, as well as an R script file (.R file) that shows the code you wrote. Be sure to comment your .R files well so I can understand what you are doing, and use descriptive variable names. See me if you have additional questions on homework submission You are going to take a look at a new distribution of data which we did not cover in class. This distribution is called the exponential distribution. The PDF for the exponential distribution is: where 6 represents the scale parameter that is used in the gamma distribution. You can access this distribution in R using rexp, dexp, qexp, and pexp. Try ?rexp to read about it. The exponential distribution is a special case of the gamma distribution where the shape parameter ? =1. Also, since the exponential function is always positive, it is possible to do a simple integration of the PDF over all possible values of x from 0 to x and get the CDF: F(x) = 1-e- a. Plot graphs of the PDF and CDF of the exponential distribution. Use an appropriate range in your plots. b. Set your random number seed to 35. Now, create a dataset of 1500 random numbers based off of the exponential distribution. Set your B 3.5 (your rate in the rexp function will be 1/B) Create a histogram of these data to visualize them c. Sort your data using the sort() function. Calculate the probability between the 1st and 750th, 50th and 350th, and 10ooth and 1250th datapoints after sorting your data. Also, determine the probability of getting a random value greater than the maximum value in your data. Interpret the results. d. Determine the quantile values for the 0.025 and 0.975 probabilities. Determine, using ifelse statements, what percentage of your random number data fall outside of this range. What percent should it be? You've just calculated a confidence interval! Directions: All homework will be submitted electronically through email. You will be expected to turn in a word document with your answers to any questions, as well as an R script file (.R file) that shows the code you wrote. Be sure to comment your .R files well so I can understand what you are doing, and use descriptive variable names. See me if you have additional questions on homework submission You are going to take a look at a new distribution of data which we did not cover in class. This distribution is called the exponential distribution. The PDF for the exponential distribution is: where 6 represents the scale parameter that is used in the gamma distribution. You can access this distribution in R using rexp, dexp, qexp, and pexp. Try ?rexp to read about it. The exponential distribution is a special case of the gamma distribution where the shape parameter ? =1. Also, since the exponential function is always positive, it is possible to do a simple integration of the PDF over all possible values of x from 0 to x and get the CDF: F(x) = 1-e- a. Plot graphs of the PDF and CDF of the exponential distribution. Use an appropriate range in your plots. b. Set your random number seed to 35. Now, create a dataset of 1500 random numbers based off of the exponential distribution. Set your B 3.5 (your rate in the rexp function will be 1/B) Create a histogram of these data to visualize them c. Sort your data using the sort() function. Calculate the probability between the 1st and 750th, 50th and 350th, and 10ooth and 1250th datapoints after sorting your data. Also, determine the probability of getting a random value greater than the maximum value in your data. Interpret the results. d. Determine the quantile values for the 0.025 and 0.975 probabilities. Determine, using ifelse statements, what percentage of your random number data fall outside of this range. What percent should it be? You've just calculated a confidence interval

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!