Displaying 20 results from an estimated 3000 matches similar to: "Weighting data with normal distribution"
2013 Mar 18
2
Fit a mixture of lognormal and normal distributions
Hello
I am trying to find an automated way of fitting a mixture of normal and log-normal distributions to data which is clearly bimodal.
Here's a simulated example:
x.1<-rnorm(6000, 2.4, 0.6)x.2<-rlnorm(10000, 1.3,0.1)X<-c(x.1, x.2)
hist(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
2009 Jun 13
1
Fitting Mixture of Non-Central Student's t Distributions
Dear all,
I am attempting to model some one-dimensional data using a mixture model
of non-central Student's t distributions. However, I haven't been able
to find any R package that provides this functionality.
Could there be a way to "manipulate" the EM algorithms from the mixdist
or mixtools package to fit the model, or do you have any other
suggestions?
If anyone could help
2009 Nov 03
1
fitting a confined mixture model
Hello all,
I would like to fit a mixture model whose components are normal
distributions confined in a closed interval. Since there are already
several packages for EM, I would like to extend one of these instead of
writing a new script from scratch. What would be the best way to
customize such an existing package for doing that? Which one is the best
in terms of extensibility? (e.g mixtools,
2007 Oct 15
1
how to use normalmixEM to get correct result?
Dear R-Users,
I have a large number of data(54000) and the field of data is 50 to 2.0e9. I want to use normalmixEM (package:mixtools) 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)
2011 Aug 25
1
How to combine two learned regression models?
Hi All,
I have a set of features of size p and I would like to separate my feature space into two sets so that p = p1 + p2, p1 is a set of features and p2 is another set of features and I want to fit a glm model for each sets of features separately. Then I want to combine the results of two glm models with a parameter beta. For example, beta * F(p1) + (1-beta) * F(p2) where F(p1) is a learned
2008 Jul 16
1
Problem with mpi.close.Rslaves()
I am running R 2.7.0 on a Suse 9.1 linux cluster with a job scheduler
dispatching jobs and openmpi-1.0.1. I have tried running one of the
examples at http://ace.acadiau.ca/math/ACMMaC/Rmpi/examples.html in Rmpi
and they seem to be working, except mpi.close.Rslaves() hangs. The
slaves are closed, but the master doesn't finish its script. Below is
the example script and the call to R. The job is
2012 Mar 05
1
Fitting & evaluating mixture of two Weibull distributions
Hello,
I would like to fit a mixture of two Weibull distributions to my data, estimate the model parameters, and compare the fit of the model to that of a single Weibull distribution.
I have used the mix() function in the 'mixdist' package to fit the mixed distribution, and have got the parameter estimates, however, I have not been able to get the log-likelihood for the fit of this model
2008 Jul 16
2
Howto view function's source code of an installed package
Hi,
Is there a way I can view the functions source code of a
package I installed in my PC.
For example I downloaded the great "mixtools" package.
I want to see the source code of one of its function "normalmixEM"
Is there a way to do it? Presumably from R command prompt?
I tried to take a look at the zip file, but somehow I can't seem
to find the file on which I can
2007 Jan 10
0
Installation problem with package mixtools
I am trying to install mixtools on Debian Etch and get the following error
dell-2 /usr/lib # R CMD INSTALL mixtools_0.1.0.tar.gz
* Installing *source* package 'mixtools' ...
** libs
gcc -I/usr/share/R/include -I/usr/share/R/include -fpic -g -O2 -std=gnu99 -c new_svalues.c -o new_svalues.o
gfortran -fpic -g -O2 -c sphericaldepth.f -o sphericaldepth.o
make: gfortran: Command not
2011 Aug 30
2
Multivariate Normal: Help wanted!
I have the following function, a MSE calc based on some Multivariate normals:
MV.MSE<-function(n,EP,X,S){
(dmvnorm(X,mean=rep(0,2),I+S+EP)-dmvnorm(X,mean=rep(0,2),I+S))^2
+
1/n*(dmvnorm(X,mean=rep(0,2),1+S+EP/2)*det(4*pi*EP)^-.5-
(dmvnorm(X,mean=rep(0,2),I+S+EP ))^2)}
I can get the MV.MSE for given values of the function e.g
2011 Oct 01
1
Fitting 3 beta distributions
Hi,
I want to fit 3 beta distributions to my data which ranges between 0 and 1.
What are the functions that I can easily call and specify that 3 beta
distributions should be fitted?
I have already looked at normalmixEM and fitdistr but they dont seem to be
applicable (normalmixEM is only for fitting normal dist and fitdistr will
only fit 1 distribution, not 3). Is that right?
Also, my data has 26
2011 Jan 06
0
Set axis limits in mixtools plot
Hello,
Can the x and y axis limits be specified in a density plot with the
mixtools package for a finite mixture model? Uncommenting the xlim2/
ylim2 lines in the plot command below generates 'not a graphical
parameter' warnings (and does not change the axis settings), and
uncommenting the xlim/ylim lines generates a 'formal argument "ylim"
matched by multiple actual
2016 Jul 27
2
Weighting Schemes: Implementing Piv+ Normalization
Hi,
I have added support for Piv normalization in Tf-Idf weighting scheme as a
intermediate step to implementing the support for Piv+ normalization. All
tests pass.
But I'm running into some issues with Piv+ normalization. In the Piv+
formula , there are two parameters (s and delta) that control the weight
assigned. I think the way I'm serialising and unserialising these
parameters has
2013 Mar 30
1
normal mixture EM not working?
Hi,
I am currently working on fitting a mixture density to financial data.
I have the following data:
http://s000.tinyupload.com/?file_id=00083355432555420222
I want to fit a mixture density of two normal distributions.
I have the formula:
f(l)=πϕ(l;μ1,σ21)+(1−π)ϕ(l;μ2,σ22)
my R code is:
normalmix<-normalmixEM(dat,k=2,fast=TRUE)
pi<-normalmix$lambda[1]
mu1<-normalmix$mu[1]
2009 Aug 06
0
Fitting Mixture of Non-Central Student's t Distributions
Dear Ingmar & Dave,
Thanks a lot for your help and sorry for the late reply.
Finally, I've found a way to separate the mixture of distributions
(empirically). But the gamlss package looks great, I'm sure it will help
me during my further studies.
Kind regards,
Susanne
On 15 Jun 2009, at 20:09, Ingmar Visser wrote:
> Dear Susanne & Dave,
>
> The gamlss package family
2011 Mar 22
0
EM and Mixtools
I have 2 questions concerning the EM algorithm. Is it true that the
EM algorithm gives unique answers for the means and variances of a mixture
of 2 normals? I am using mixtools and I am surprised that it works better
than a Bayesian program I wrote.
If so can someone say why the mixing probabilities are so good?
--
Thanks,
Jim.
[[alternative HTML version deleted]]
2011 Aug 19
0
question about mixtools package
Hello all,
May be silly question, but what exactly is beta parameter in functions like
regmixEM from mixtools package?
I mean, how to determine this beta, if i have a set of metrics for each
case? Is there a function for that? I have try to put NULL at this
parameter, but function just do not work in this case.
Cheers,
Dima
[[alternative HTML version deleted]]
2013 Apr 09
0
[R-SIG-Finance] EM algorithm with R manually implemented?
Moved to R-help because there's no obvious financial content.
Michael
On Sat, Apr 6, 2013 at 10:56 AM, Stat Tistician
<statisticiangermany at gmail.com> wrote:
> Hi,
> I want to implement the EM algorithm manually, with my own loops and so.
> Afterwards, I want to compare it to the normalmixEM output of mixtools
> package.
>
> Since the notation is very advanced, I
2008 Oct 22
3
Help finding the proper function
This might not be the correct forum for this question for there might be some
flaws in my logic so the R function I'm looking for might not be the
correct, but I know there?s a lot of smart people in this forum so please
correct me if I'm wrong. I have been googling and searching in this forum
for something useful but so far I'm out of luck.
This is the background to my problem. I
2016 Jul 29
2
Weighting Schemes: Implementing Piv+ Normalization
> `ptr` is, if I inferred correctly, a `const char *`. (I'm not sure,
> because I don't know why you're incrementing it. Please push your code
> to github if you need further help so people can see the entire
> context of your changes.)
I've pushed all the changes I made so far
https://github.com/xapian/xapian/compare/master...ivmarkp:piv+?diff=split&name=piv%2B