フィルターのクリア

how to prolong the fit distribution curve to reach x-axis ?

3 ビュー (過去 30 日間)
Amr Hashem
Amr Hashem 2015 年 10 月 31 日
コメント済み: Star Strider 2015 年 11 月 1 日
I got the best fit distribution to a failure rate (data)
Now I want to prolong the fitted distribution curve to reach x-axis (in both tails)
I use:
binWidth = 1;
binCtrs = 0:binWidth:18;
figure
hist(data,binCtrs);
counts = hist(data,binCtrs);
nu = length(data);
prob = counts / (nu * binWidth); % rescale the figure
figure
plot(binCtrs,prob,'ro');
paramEsts = gevfit(data); %estimate parameter
xgrid = linspace(0,18,100);
pdfEst = gevpdf(xgrid,paramEsts(1),paramEsts(2),paramEsts(3)); hold on;
line(xgrid,pdfEst,'color','b')
to (fit distribution &) produce this figure:
Now , I want to prolong/extend the curve to reach x-axis
I try:
xaxis=linspace(-5,22); % create Matching vector
line(xaxis,pdfEst,'color','r')
but it produced another distribution.

採用された回答

Star Strider
Star Strider 2015 年 10 月 31 日
According to the documentation on the Generalized Extreme Value Distribution particualrly the Examples section, it may or it may not have a zero probability at some value of x. (It will never cross zero.) It all depends on what the distribution is for your data. Extend your xgrid vector in the negative and positive directions and see what it does.
Experiment!

その他の回答 (1 件)

Amr Hashem
Amr Hashem 2015 年 10 月 31 日
I got it...
xgrid = linspace(-20,20,100);

Community Treasure Hunt

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

Start Hunting!

Translated by