Re: [R] Programmation pour MLE

From: Dirk Eddelbuettel <edd_at_debian.org>
Date: Fri 23 Jul 2004 - 00:26:34 EST

On Thu, Jul 22, 2004 at 06:48:58AM +0200, Ahmed Elhabti wrote:
> Je veux cherch? l?estimateur de vraisemblance maximal (MLE)d?une fonction ? 3 param?tre inconue ?tant donn? une ?chantillon de taille 50 (les observations des valeurs de x) alors comment je peux proc?d?
>
> La fonction de densit? est d?finie par :
>
>
>
> f(x)= 1/3(g(a1)+g(a2)+g(a3))
>
>
>
> avec g(ai)=(exp(ai)*ai^x)/x! pour i=1,2,3.

The list language is English, so please pardon my reply for using it.

This should be reasonably straightforward with optim() and a simple function that sums the terms of the log-likelihood, see help("optim").

There is also the mle function / class in stats4 which may help you as it wraps around optim(), see help("mle", package="stats4").

> Je vous remercie beaucoup.

De rien.

Dirk

-- 
Those are my principles, and if you don't like them... well, I have others.
                                                -- Groucho Marx

______________________________________________
R-help@stat.math.ethz.ch mailing list
https://www.stat.math.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Received on Fri Jul 23 00:34:42 2004

This archive was generated by hypermail 2.1.8 : Wed 03 Nov 2004 - 22:55:11 EST