(Solved): generate a matlab code with comments MATLAB is a powerful tool that could aid us when dealing with ...
generate a matlab code with comments
MATLAB is a powerful tool that could aid us when dealing with random numbers. You can generate a set of random variables that belong to a specific distribution, plot the PDF and the CDF, find the mean and the variance of the set of data via built in functions. As a starting point, visit the documentation page for "random" to learn how to generate a set of random variables following a specific distribution. Your objective in this assignment is to utilize MATLAB to analyze both the Poisson and the normal probability distribution functions. a) For the Poisson distribution use the following parameters: i. X∼Pois(5) ii. X∼Pois(50) b) For the normal distribution use the following parameters: i. X∼N(8,64) ii. X∼N(8,16) 1. Write a script that for a given distribution function (a) Generates a random data vector. - The size of the random data vector should be atleast 5∗104 points (b) Plot the PDF and CDF for each probability distribution. Carefully label your plots.