Skip to content
Back to formatted view

Raw Message

Message-ID: <A4892799-AAC1-4C48-B1D7-39B6515BA775@gmail.com>
Date: 2011-10-28T22:44:23Z
From: michael.weylandt at gmail.com (R. Michael Weylandt
Subject: Error in optim
In-Reply-To: <1319836240344-3949218.post@n4.nabble.com>

Why don't you try substituting your vector of values and see what comes out...once you figure out what happened, the sum() command will solve your problems. 

Michael

On Oct 28, 2011, at 5:10 PM, djbanana <karl79264219 at gmail.com> wrote:

> I understand that the likelihood function is a product and hence the log
> likelihood function is a sum. However I can't figure out what the problem
> is.
> 
> Here's the likelihood function:
> 
> [(alpha1*beta2*gamma)^v1 exp^(-alpha1*beta2*gamma)]/v1! * [(alpha2*beta1)^v2
> exp^(-alpha2*beta1)]/v2!
> 
> Isn't the log-likelihood function as I calculated before?
> 
> Thanks,
> DJ
> 
> --
> View this message in context: http://r.789695.n4.nabble.com/Error-in-optim-tp3948980p3949218.html
> Sent from the R help mailing list archive at Nabble.com.
> 
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.