[R] Problem with multinom ?

John Fox jfox at mcmaster.ca
Sat Jun 11 23:17:52 CEST 2005


Dear Marc,


> -----Original Message-----
> From: Marc Girondot [mailto:marc.girondot at ese.u-psud.fr] 
> Sent: Saturday, June 11, 2005 2:16 PM
> To: John Fox
> Cc: R-help at r-project.org
> Subject: RE: [R] Problem with multinom ?
> 
> >Dear Marc,
> >
> >I get the same results -- same coefficients, standard errors, and 
> >fitted probabilities -- from multinom() and glm(). It's true 
> that the 
> >deviances differ, but they, I believe, are defined only up 
> to an additive constant:
> >
> >>  predict(dt.b, type="response")
> >         1         2         3
> >0.4524946 0.5032227 0.5538845
> >
> >>  predict(dt.m, type="probs")
> >         1         2         3         4         5         6
> >0.4524948 0.4524948 0.5032229 0.5032229 0.5538846 0.5538846
> >
> >These fitted probabilities *are* correct: Since the members of each 
> >pair (1,2), (3,4), and (5,6) have identical values of factor 
> they are 
> >identical fitted probabilities.
> 
> I expected rather to obtain (note 1- before some terms):
> >     1         2         3         4         5         6
> 0.4524948 1-0.4524948 0.5032229 1-0.5032229 0.5538846 1-0.5538846
> 
> ...

But the fitted probabilities are for each observation in the data set; in
your data, these have identical values of factor for each pair and hence
identical fitted probabilities. When the response is dichotomous, you get
only one of the two fitted probabilities for each observation; for a
polytomous response, you get a matrix of fitted probabilities which sum to 1
row-wise.

Regards,
 John

> 
> Marc
> -- 
> 
> __________________________________________________________
> Marc Girondot, Pr
> Laboratoire Ecologie, Systématique et Evolution Equipe de 
> Conservation des Populations et des Communautés CNRS, ENGREF 
> et Université Paris-Sud 11 , UMR 8079 Bâtiment 362
> 91405 Orsay Cedex, France
> 
> Tel:  33 1 (0)1.69.15.72.30   Fax: 33 1 (0)1 69 
> 15 56 96   e-mail: marc.girondot at ese.u-psud.fr
> Web: http://www.ese.u-psud.fr/epc/conservation/Marc.html
> Skype: girondot
> Fax in US: 1-425-732-6934




More information about the R-help mailing list