Displaying 2 results from an estimated 2 matches for "arbmean".
Did you mean:
amean
2007 Oct 15
1
how to use normalmixEM to get correct result?
...tools) to fit them in finite mixture narmal distributions,but get some mistakes.I don't know which steps make the error.
I have used the following functions before
>x<-read.table("data")
>log.x<-log10(x$V1)
>log.x<-sort(log.x)
>outx = normalmixEM(log.x,arbmean = TRUE, arbvar = TRUE, k=2,epsilon = 1e-03,maxit = 10000, verb = FALSE)
The output is given as:
Need new starting values due to singularity...
Need new starting values due to singularity...
Need new starting values due to singularity...
error in normalmixEM(log.x, arbmean = TRUE, arbv...
2013 Mar 18
2
Fit a mixture of lognormal and normal distributions
...(X,100,freq=FALSE, ylim=c(0,1.5))lines(density(x.1), lty=2, lwd=2)lines(density(x.2), lty=2, lwd=2)lines(density(X), lty=4)
Currently i am using mixtools and just run:
library(mixtools)mixmdl = normalmixEM(X, k=2, epsilon = 1e-08, maxit = 1000, maxrestarts=20, verb = TRUE, fast=FALSE, ECM = FALSE, arbmean = TRUE, arbvar = TRUE) plot(mixmdl,which=2)lines(density(X), lty=2, lwd=2)
This is obviously not the best way of doing this. The estimates it gives me are:mu 3.6595737(x.2 log()=1.29) 2.3113135(x.1)
These are not too far off but I was wondering if someone knows of a better R package/way of doing th...