STAT 452/652 - MINITAB LAB 1 Plan: 1. Computations of probabilities, cdf and quantile function for theoretical distributions • Continuous • Discrete 2. Random sample generation from theoretical distributions; 3. Histograms: information about the underlying/model distribution’s pdf; 4. Random sample generation - FTSS in action. LAB WORK 1. Computations of probabilities, cdf and quantile function for theoretical distributions • Continuous Normal. (a) Find the probability that a normal random variable with mean 1 and standard deviation 2 is smaller than 3, that is find its cdf at 3. In MINITAB: Calc-Probability Distributions-Normal: (1) fill mean and standard deviation boxes; (2) ask for cumulative probability, (3) input constant 3. Result: 0.8413. (b) Find the probability that a normal random variable with mean 1 and standard deviation 2 is larger than 3. Need to find cdf F at 3 and take 1 − F (3) = 1 − 0.8413 = 0.1587. (c) Find the probability that a normal random variable with mean 1 and standard deviation 2 is larger than -2 but smaller than 2. Find the difference between cdf at 2 and -2. P (−2 < X < 2) = F (2) − F (−2) = 0.6915 − 0.0668 = 0.6247. (d) Find the 85th percentile of a normal distribution with mean 1 and standard devaition 2. In MINITAB: Calc- Probability Distributions-Normal: (1) fill mean and standard deviation boxes; (2) ask for INVERSE CUMULATIVE PROBABILITY, (3) input constant 0.85. Result: 3.0729. • Discrete Binomial. (a) Find the probability that a binomial random variable with number of trials 10 and probability of success 0.6 is equal to 5. In MINITAB: Calc- probability Distributions-Binomial: (1) fill number of trials and probability of success boxes; (2) ask for probability, (3) input constant 5. Result: 0.2007. 1 (b) Find the probability that a binomial random variable with number of trials 10 and probability of success 0.6 is larger than 5. Need to find cdf F at 5 and take 1 − F (5) = 1 − 0.3669 = 0.6331. (c) Find the 85th percentile of a binomial random variable with number of trials 10 and probability of success 0.6. In MINITAB: Calc- Probability DistributionsBinomial: (1) fill number of trials and probability of success boxes; (2) ask for INVERSE CUMULATIVE PROBABILITY, (3) input constant 0.85. Results: P (X ≤ 7) = 0.8327 and P (X ≤ 8) = 0.9536. Remember we need q = min{x : F (x) ≥ 0.85} = 8. 2. Random sample generation from theoretical distributions; • Uniform. Generate a random sample of size 100 from U(-1, 3). In MINITAB: Calc-Random Data-Uniform; (1) fill: generate 100 rows, (2) fill lower and upper endpoints as -1 and 3, (3) provide storage column, say C1. • Binomial. Generate a random sample of size 10 from B(10, 0.1). In MINITAB: Calc-Random Data-Binomial; (1) fill: generate 10 rows, (2) fill numer of trials and probability of success, as 10 and 0.1 (3) provide storage column, say C2. 3. Histograms: information about the underlying/model distribution’s pdf; • Lognormal. Generate a density histogram of a sample of size 200 from a lognormal distribution with location 0 and scale 5. First generate the sample and store in a column, say C3. Then in MINITAB: Graph - Histogram: (1) fill Graph variables, say C3, (2) Options-Type of Histogram: fill Density. What can you say about the symmetry of the lognormal distribution from the histogram? • t-distribution. Generate a frequency histogram of a sample of size 500 from a tdistribution with 10 degrees of freedom. First generate the sample and store in a column, say C4. Then in MINITAB: Graph - Histogram: (1) fill Graph variables, say C4, (2) Options-Type of Histogram: fill Frequency. What can you say about the symmetry of the t-distribution from the histogram? 4. Random sample generation - FTSS in action. Generate a sample of size 1000 from a normal distribution with mean 0 and standard deviation 1 using the FTSS. (1) Generate a sample from U(0,1) of size 1000; (2) Compute inverse normal CDF on that sample; (3) Graph histograms of the sample from the uniform and the sample resulting from the inverse cdf calculation and see if they look like samples from uniform and normal distributions. 2 HOMEWORK 1. Due class time, Wednesday, September 19. 1. (Stat 452 only) Suppose that only 25% of all drivers come to a complete stop at an intersection having flashing red lights in all directions when no other cars are visible. What is the probability that, of 20 randomly chosen drivers coming to an intersection under these conditions, (a) At most 6 will come to a complete stop? (b) Exactly 6 will come to a complete stop? (c) How many of the next 20 drivers do you expect to come to a complete stop? 2. The results of an entry test for a data processing company have a normal distribution with mean 60 and standard deviation 10. Only the top 2 percent of applicants who took the test will be hired. (a) What is the lowest score of a hired applicant? (b) What percentage of applicants scored between 50 and 65? 3. What happens to the histogram when we increase the sample size? Generate histograms of samples of size: 100, 1000, 10,000 from a normal distribution with mean 0 and standard deviation 1. What happens to the histogram as you increase the sample size? What curve does the histogram approximate better and better when we increase sample size? 4. Let X have an exponential distribution with mean 2 (a) Find the probability that X is larger than 3. (b) Find the 20th percentile of X. 5. Let X have a binomial distribution with 20 trials and probability of success 0.7 on each trial. (a) Find the probability that X is greater than 5 and less than or equal to 12. (b) Find the 65th percentile of X. (c) Find 50th percentile of X. 6. Stat 652 only I want to generate one observation from a Pareto distribution with shape parameter α which has the following pdf: f (x) = ( α xα+1 0 if x ≥ 1; otherwise. Suppose I have a random number generator, and I generated an observation from the uniform distribution on the interval (0,1). The observation I generated is 0.5. Using the FTSS I computed the value of the corresponding observation from Pareto distribution with α = 2. What was that value? 3