フィルターのクリア

find the probability in normal distibution

13 ビュー (過去 30 日間)
maryam
maryam 2015 年 5 月 25 日
コメント済み: maryam 2015 年 5 月 25 日
hi everyone. i have two normal distribution curves which met each other at two points A and B. how can i find these two points and then how can i calculate the probability between (-inf,A), (A,B) and (B, inf) for each curve? thank you for your time :)
  3 件のコメント
maryam
maryam 2015 年 5 月 25 日
dear cyclist,i have the equations of the curves.(mu and sigma of normal distribution are known so i can plot these graphs).
the cyclist
the cyclist 2015 年 5 月 25 日
Someone here may be able to help you, but you should be aware that what you are asking is not really a MATLAB problem, but rather a math problem. You might also want to seek help on a math forum.

サインインしてコメントする。

採用された回答

dpb
dpb 2015 年 5 月 25 日
編集済み: dpb 2015 年 5 月 25 日
Approximate (to nearest point of x vector) is fairly simple to do. Define
f=@(x)normpdf(x,mu1,s1)-normpdf(x,mu2,s2)
as the difference between the two. Then simply evaluate and look for the zero crossings--to illustrate I can approximate your plot pretty closely with
>> mu1=-30;s1=30; mu2=mu1; s2=s1/2;
>> x=-150:150;
>> d=f(x);
>> ix=find(diff(dd))+1
ix =
101 142
>> f(x(ix))
ans =
1.0e-03 *
-0.2857 0.4266
>> figure
>> plot(x,[y1;y2;d].')
>> grid on
You can either refine these with an interpolating function around the located values or use a finer mesh for x, noting you don't need the full range to find the intersecting points.
Or, you can solve directly using fzero or similar root solver.
Once you've got the points, the percentiles should be easy enough just standardize those x-values found to the standard normal variate using the known parameters.
  1 件のコメント
maryam
maryam 2015 年 5 月 25 日
thank you very much :)

サインインしてコメントする。

その他の回答 (1 件)

John D'Errico
John D'Errico 2015 年 5 月 25 日
What is the problem? Just use fzero on the difference between the two PDFs to find the intersection points. Then use normcdf to find the area you desire.

カテゴリ

Help Center および File ExchangeExploration and Visualization についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by