Re: [R] Bimodal distribution

2010-02-25 Thread Greg Snow
ject.org] On Behalf Of Samor Gandhi > Sent: Wednesday, February 24, 2010 5:23 AM > To: r-help@r-project.org > Subject: [R] Bimodal distribution > > Hello, > > Is there any test  for bimodality in R that > > x <- c(rnorm(1000,0,1),rnorm(1000,3,1)) > hist(x,nclas

Re: [R] Bimodal distribution

2010-02-25 Thread Samor Gandhi
Hi Ingmar, Thank you for your reply! How to fit a mixture distribution to the data, do you mean by using mixed model? Regards, Samor --- On Wed, 24/2/10, Ingmar Visser wrote: From: Ingmar Visser Subject: Re: [R] Bimodal distribution To: "Samor Gandhi" Cc: r-help@r-projec

Re: [R] Bimodal distribution

2010-02-24 Thread Ingmar Visser
Samor, A somewhat indirect answer: you could fit a mixture distribution to your data and test how many components are needed to best describe your data. hth, Ingmar On Wed, Feb 24, 2010 at 1:22 PM, Samor Gandhi wrote: > Hello, > > Is there any test for bimodality in R that > > x <- c(rnorm(1

[R] Bimodal distribution

2010-02-24 Thread Samor Gandhi
Hello, Is there any test  for bimodality in R that x <- c(rnorm(1000,0,1),rnorm(1000,3,1)) hist(x,nclass=100) Thank you in advance for any help. Regards, Samor [[alternative HTML version deleted]] __ R-help@r-project.org mailing list

Re: [R] Bimodal Distribution

2008-05-29 Thread Andrew Robinson
Hi Mike, if you can decompose the bimodal distribution into (eg two) known forms, then you could try a stepwise approach, eg: If uniform < 0.5 then double it and use it to draw from the inverse cdf of A, else, double (uniform - 0.5) and use it to draw from the inverse cdf of B. You can change

[R] Bimodal Distribution

2008-05-29 Thread Mike Williams
Hello R Users, I am doing a Latin Hypercube type simulation. I have found the improvedLHS function and have used it to generate a bunch of properly distributed uniform probabilities. Now I am using functions like qlnorm to transform that into the appropriately lognormal or triangularly distri