Question: Complete the functions. Thanks. Gaussian Distribution A gaussian distribution with mean u, standard deviation o. Sample data from this distribution using sample(gd, n). You can

 Complete the functions. Thanks. Gaussian Distribution A gaussian distribution with mean

Complete the functions. Thanks.

Gaussian Distribution A gaussian distribution with mean u, standard deviation o. Sample data from this distribution using sample(gd, n). You can also get the mean (mean), standard deviation (stddev), and variance (var) through their corresponding functions. Main.workspace5. GaussianDistribution # The block of text below add documentation to julia struct or function. # Check out the live docs to the right when your cursor # is in GaussianDistribution. GaussianDistribution (u:: Float64, 0::Float64) A gaussian distribution with mean u, standard deviation o. Sample data from this distribution using 'sample (gd, n)'. You can also get the mean ('mean (gd)'), standard deviation ('stddev(gd)'), and variance ('var(gd)') through their corresponding functions. struct GaussianDistribution ::Float64 # mean 0::Float64 # standard deviation end 600 us mean (generic function with 2 methods) mean(gd:: GaussianDistribution) = gd. 15.2 us stddev (generic function with 2 methods) stddev(gd:: GaussianDistribution) = gd.o 12.2 us var (generic function with 2 methods) var(gd:: GaussianDistribution) = gd.o12 18.3 us sample (generic function with 2 methods) function sample (gd:: GaussianDistribution, n = 1) gd.o*randn(n) .+ gd. end

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!