'Re-draw figure in MATLAB
I get two excel file for x axis and y axis respectively and load into the MATLAB. After that, I insert these two vectors in curve fitting tool in MATLAB to get mean and std value by linear interpolant. I use 'lognormal' function to re-draw this figure. But I can't get the same figure. I don't know why it is wrong. I hope someone could help me, thank you! My code is shown below:
m=64.83;
std=35.47;
v=std^2;
mu=log(m^2/sqrt(v+m^2));
sigma=sqrt(log(v/m^2+1));
p1=0:1:150;
p2=logncdf(p1,mu,sigma);
plot(p1,p2)
Where m means mean value, std means stand deviation, v means variance, mu and sigma are lognormal distribution parameters.
I look forward to hearing your suggestions, thank you!
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
