[SOLVED] CS代考 % ————————————————————————-

30 $

File Name: CS代考_%_————————————————————————-.zip
File Size: 791.28 KB

SKU: 3056384116 Category: Tags: , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,

Or Upload Your Assignment Here:


% —————————————————————————-
% This Matlab code allows you to verify the Central Limit Theorem (CLT)
% The population is Exponential with mean = true_mean
% —————————————————————————-

Copyright By PowCoder代写加微信 assignmentchef

% clean up the environment

% sample size
sample_size = 10000;% Choose the number of observations for each sample
smaller_sample_size = 1000; % Choose the number of observations for each (smaller) sample
number_of_samples = 1000;% Choose the number of samples

% population parameters
true_mean = 2; % mean of the population

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

%—————————————————————————————————————–
% The CLT for the mean WITHOUT standardization –
% As the number of observations increases, the distribution of the “sample” mean
% becomes more and more concentrated around the “population” mean –
% In fact, the variance of the sample mean goes to zero (see slides for Lecture 1)
%—————————————————————————————————————–

% initialize the vectors
small_sample = zeros(smaller_sample_size, number_of_samples);
sz = size(small_sample);
larger_sample = zeros(sample_size, number_of_samples);
sz1 = size(larger_sample);

% create small and large samples
X_small = random(‘Exponential’, true_mean, sz);
X_large = random(‘Exponential’, true_mean, sz1);

% compute the mean of each sample
mean_small = mean(X_small);
mean_large = mean(X_large);

% plot the distribution of the sample means
histogram(mean_small,’normalization’,’pdf’, “FaceColor”, “red”);
histogram(mean_large,’normalization’,’pdf’, “FaceColor”, “blue”);

程序代写 CS代考加微信: assignmentchef QQ: 1823890830 Email: [email protected]

Reviews

There are no reviews yet.

Only logged in customers who have purchased this product may leave a review.

Shopping Cart
[SOLVED] CS代考 % ————————————————————————-
30 $