# Matlab probability

• Apr 20th 2010, 04:15 PM
2clients
Matlab probability
Hello,

Here's the question I'm trying to answer:

You take many temperature readings in Monterey Bay and find a mean temperature, T = 12 C. The standard deviation of temperature measurements is given by sigma_T = 2 C. Assuming the data are normally distributed, what fraction of your readings do you expect to be between

(a) 10 and 14 C? - this is easy - it is one sigma away so I would expect approximately 68% in that range.

(b) 8 and 16? similarly - two sigmas away so approximately 95%

(c) 6 and 8?

(d) 11.5 and 12.5?

(c) and (d) are where I'm having trouble. It seems there is a normdist function on excel that would calculate this, but I need to do everything via Matlab.

Thank you very much for any help!
• Apr 20th 2010, 11:22 PM
CaptainBlack
Quote:

Originally Posted by 2clients
Hello,

Here's the question I'm trying to answer:

You take many temperature readings in Monterey Bay and find a mean temperature, T = 12 C. The standard deviation of temperature measurements is given by sigma_T = 2 C. Assuming the data are normally distributed, what fraction of your readings do you expect to be between

(a) 10 and 14 C? - this is easy - it is one sigma away so I would expect approximately 68% in that range.

(b) 8 and 16? similarly - two sigmas away so approximately 95%

(c) 6 and 8?

(d) 11.5 and 12.5?

(c) and (d) are where I'm having trouble. It seems there is a normdist function on excel that would calculate this, but I need to do everything via Matlab.

Thank you very much for any help!

CB
• Apr 21st 2010, 08:48 AM
2clients
Thank you. I have certainly googled this topic, and I did not find an efficient method. Thank you for your help.

It seems I may be able to use the erf function, but I'm not sure how.
• Apr 21st 2010, 12:55 PM
CaptainBlack
Quote:

Originally Posted by 2clients
Thank you. I have certainly googled this topic, and I did not find an efficient method. Thank you for your help.

It seems I may be able to use the erf function, but I'm not sure how.

Did you read the first hit on the link to the search that I posted? Well read it!

CB