Path: news.mathworks.com!not-for-mail
From: "Bruno Luong" <b.luong@fogale.findmycountry>
Newsgroups: comp.soft-sys.matlab
Subject: Re: How can I find the mean between to points of normal distribution?
Date: Mon, 2 Aug 2010 21:05:24 +0000 (UTC)
Organization: FOGALE nanotech
Lines: 15
Message-ID: <i37buk$s8b$1@fred.mathworks.com>
References: <i371ts$ht3$1@fred.mathworks.com>
Reply-To: "Bruno Luong" <b.luong@fogale.findmycountry>
NNTP-Posting-Host: webapp-02-blr.mathworks.com
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 8bit
X-Trace: fred.mathworks.com 1280783124 28939 172.30.248.37 (2 Aug 2010 21:05:24 GMT)
X-Complaints-To: news@mathworks.com
NNTP-Posting-Date: Mon, 2 Aug 2010 21:05:24 +0000 (UTC)
X-Newsreader: MATLAB Central Newsreader 390839
Xref: news.mathworks.com comp.soft-sys.matlab:658439

"BobC Cadenza" <bobc@mailinator.com> wrote in message <i371ts$ht3$1@fred.mathworks.com>...
> Given a normal distribution with mu,sigma.  How can I find the mean between two points?  So for example I want to find the mean value between -.5 *sigma to +2 sigma?
> 
> Thanks

Take a look at my FEX submission:

http://www.mathworks.com/matlabcentral/fileexchange/23832-truncated-gaussian

sigma=2; 
[trash meaneff sigmaeff]=TruncatedGaussian(-sigma,[-0.5*sigma 2*sigma]);
disp(meaneff)
% The mean is  0.8915

Bruno