Starting from:
$30

$24

Data Science Assignment 4: Distributions Solved

Question 4.1: Exploring Distributions

Distributions are e ectively de ned by type and parameters. This assignment focuses on exploring both in visual manner. You are supposed to produce histograms for generated random values from a given distribution type with certain parameters.

Create a separate PDF les (not the probability density function) for a normal, exponential, binomial, Poisson distribution and another type you choose. For each type: Explore two parameters that you select with respect to the type (which might also be the sample size (n) which is not a classical parameter); decide on reasonable values for both parameters; generate corresponding random values; and explore the generated values visually in a two-dimensional grid of histograms with respect to the parameters. We added an example for the gamma distribution in that you have a visual impression of a correct grid of histograms.

Some hints on how to produce such grids are the following (but you will de nitely need some additional google searches):

In R, you can arrange such grid by, e.g., par(mfcol = c(4,4)) for a 4x4 grid. Hereafter, you can    ll the
    • plots using the basic plotting machinery.

In Python, you can use fig, ax = plt.subplots(nrows=4, ncols=4), iterate the axis and use it in the plotting machinery.

You can also increase the dimensions (you are not limited to 4x4 plots). In some case, it may also help to adjust the x and y limits of the plot to better show the di erences between values for parameters.

Please submit the 5 PDF    les and the code for producing them.




1

More products