Clear Filters
Clear Filters

Generate a vector X of 100 independent samples from Gaussian distribution

5 views (last 30 days)
Generate a vector X of 100 independent samples from Gaussian distribution with mean=5 and variance =3.

Accepted Answer

Thorsten
Thorsten on 15 Sep 2016
X = sqrt(3)*randn(100, 1) + 5;

More Answers (1)

s.p4m
s.p4m on 15 Sep 2016
You could also use the random comand
X = random('norm',5,3,100,1);

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!