Path: news.mathworks.com!not-for-mail
From: <HIDDEN>
Newsgroups: comp.soft-sys.matlab
Subject: Gaussian Mixture
Date: Wed, 25 Mar 2009 03:00:04 +0000 (UTC)
Organization: The MathWorks, Inc.
Lines: 5
Message-ID: <gqc6nk$h5n$1@fred.mathworks.com>
Reply-To: <HIDDEN>
NNTP-Posting-Host: webapp-02-blr.mathworks.com
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: 8bit
X-Trace: fred.mathworks.com 1237950004 17591 172.30.248.37 (25 Mar 2009 03:00:04 GMT)
X-Complaints-To: news@mathworks.com
NNTP-Posting-Date: Wed, 25 Mar 2009 03:00:04 +0000 (UTC)
X-Newsreader: MATLAB Central Newsreader 1731476
Xref: news.mathworks.com comp.soft-sys.matlab:527473


So,

I have to generate 1000 samples distributed according to Gaussian Mixture distribution. And it has to consist of the sum of two distribution N(-2,1) and (2,1). weights of 0.4 and 0.6

I know that there is a method to generate the random numbers based on the inverse function of the cdf of that distribution and that's what I need to use, but I just can't figure it out.