I am trying to find the cumulative distribution function of the standard normal. I have the value that I will be using the cdf to analyze but cannot figure out the functions to go with it. Can anyone help me find the correct functions/code?

10 vues (au cours des 30 derniers jours)
Below is the code I attempted to run..but it isn't recognizing the makedist function.
x = 0.24 mu = 0 sigma = 1
pd = makedist('Normal')
y = cdf(pd,x)

Réponse acceptée

Roger Stafford
Roger Stafford le 7 Août 2013
Use matlab's 'erfc' function in place of 'normcdf' if you don't have the Statistics Toolbox according to the formula:
normcdf(x) = 1/2*erfc(-x/sqrt(2))

Plus de réponses (1)

dpb
dpb le 7 Août 2013
Seems makedist is new after R2012b 'cuz it ain't here at the release.
Use
normcdf() % and friends
instead
  2 commentaires
Kylie
Kylie le 7 Août 2013
I have tried that..so the code is: x = 0.24 mu = 0 sigma = 1
normcdf(x)
and this is the error message I get back:
??? Undefined function or method 'normcdf' for input arguments of type 'double'.
Error in ==> untitled7 at 5 normcdf(x)
dpb
dpb le 7 Août 2013
Apparently you don't have the Statistics Toolbox installed (or installed correctly, anyway).
What does
ver
return? Will list installed toolboxen and versions.

Connectez-vous pour commenter.

Community Treasure Hunt

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

Start Hunting!

Translated by