Displaying 20 results from an estimated 7000 matches similar to: ": multinom()"
2009 Feb 16
2
Using eval in multinom argument
Hi,
I am having difficulty entering a 'programmable' argument into the multinom function from the nnet package. Interactively, I can get the function to work fine by calling it this way:
z1=multinom(formula = class.ind(grp[-outgroup])~ (PC1 + PC2 + PC3), data=data.frame(scores))
However I need to be able to change the number of variables I am looking for in 'scores' and so am
2005 Apr 12
1
factors in multinom function (nnet)
Dear All:
I am interested in multinomial logit models (function multinon, library nnet) but I'm having troubles in choose whether to define the predictors as factors or not.
I had posted earlier this example (thanks for the reply ronggui):
worms<- data.frame(year= rep(2000:2004, c(3,3,3,3,3)),age=rep(1:3,5),
2006 Aug 10
1
logistic discrimination: which chance performance??
Hello,
I am using logistic discriminant analysis to check whether a known
classification Yobs can be predicted by few continuous variables X.
What I do is to predict class probabilities with multinom() in nnet(),
obtaining a predicted classification Ypred and then compute the percentage
P(obs) of objects classified the same in Yobs and Ypred.
My problem now is to figure out whether P(obs) is
2008 Aug 11
1
checking if multinom converged
Is anyone aware of a way to check whether multinom has converged by
checking a component of the output ? I'm
not familar with nnet but, since multinom calls nnet , maybe there is an
extra argument once can send to multinom to capture this
information. Thanks.
2006 Feb 22
2
does multinomial logistic model from multinom (nnet) has logLik?
I want to get the logLik to calculate McFadden.R2 ,ML.R2 and
Cragg.Uhler.R2, but the value from multinom does not have logLik.So my
quetion is : is logLik meaningful to multinomial logistic model from
multinom?If it does, how can I get it?
Thank you!
ps: I konw VGAM has function to get the multinomial logistic model
with logLik, but I prefer use the function from "official" R
2005 Nov 30
1
multinom crashes (when I do something stupid) (PR#8358)
Full_Name: Rob Foxall
Version: 2.2.0
OS: Windows XP
Submission from: (NULL) (149.155.96.5)
I was using multinom from nnet package, when I did something stupid -- I entered
in an incorrect factor variable as response. This factor had only one level.
Instead of R telling me not to be so dumb, it crashed, clicking on debug coming
up with the message "An exception 'Unhandled Win32
2005 Apr 13
2
multinom and contrasts
Hi,
I found that using different contrasts (e.g.
contr.helmert vs. contr.treatment) will generate
different fitted probabilities from multinomial
logistic regression using multinom(); while the fitted
probabilities from binary logistic regression seem to
be the same. Why is that? and for multinomial logisitc
regression, what contrast should be used? I guess it's
helmert?
here is an example
2005 May 13
1
multinom(): likelihood of model?
Hi all,
I'm working on a multinomial (or "polytomous") logistic regression
using R and have made great progress using multinom() from the nnet
library. My response variable has three categories, and there are two
different possible predictors. I'd like to use the likelihoods of
certain models (ie, saturated, fitteds, and null) to calculate
Nagelkerke R-squared values for
2005 Jul 08
1
explained deviance in multinom
Hi:
I'm working with multinomial models with library nnet, and I'm trying to get the explained deviance (pseudo R^2) of my models.
I am assuming that:
pseudo R^2= 1 - dev(model) / dev (null)
where dev(model) is the deviance for the fitted model and dev(null) is the deviance for the null model (with the intercept only).
library(nnet)
full.model<- multinom(cbind(factor1,
2009 Jun 13
1
Insignificant variable improves AIC (multinom)?
Hi,
I am trying to specify a multinomial logit model using the multinom function from the nnet package. Now I add another independent variable and it halves the AIC as given by summary(multinom()). But when I call Anova(multinom()) from the car package, it tells me that this added variable is insignificant (Pr(>Chisq)=0.39). Thus, the improved AIC suggests to keep the variable but the Anova
2005 Apr 11
1
multi-class modeling
Hi,
Just wonder if someone could comment on using linear
discriminant analysis (LDA) vs. multinomial logistic
regression in multi-class classification/prediction
(nomial dependent variable, not ordinal)? What kind of
difference in results can I expect from the 2 methods,
which is better or more appropriate, or under what
condiditon should I used one instead of the other? And
is there other
2006 Jun 27
1
weights in multinom
Best R Help,
I like to estimate a Multinomial Logit Model with 10 Classes. The
problem is that the number of observations differs a lot over the 10
classes:
Class | num. Observations
A | 373
B | 631
C | 171
D | 700
E | 87
F | 249
G | 138
H | 133
I | 162
J | 407
Total: 3051
Where my data looks like:
x1 x2 x3 x4 Class
1 1,02 2 1 A
2 7,2 1 5 B
3 4,2 1 4 H
1 4,1 1 8 F
2 2,4 3 7 D
1 1,2 0 4 J
2 0,9
2011 Apr 08
1
multinom() residual deviance
Running a binary logit model on the data
df <- data.frame(y=sample(letters[1:3], 100, repl=T),
x=rnorm(100))
reveals some residual deviance:
summary(glm(y ~ ., data=df, family=binomial("logit")))
However, running a multinomial model on that data (multinom, nnet)
reveals a residual deviance:
summary(multinom(y ~ ., data=df))
On page 203, the MASS book says that "here the
2010 Mar 17
1
question about multinom function (nnet)
Dear All.
I have the following table that I want to analyze using multinom
function
freq segments sample
4271 Seg1 tumour
4311 Seg2 tumour
3515 Seg1 normal
3561 Seg2 normal
I want to compare model with both factors to the one where only sample
is present.
model1=multinom(freq~segments+sample,data=table)
model2=multinom(freq~ sample,data=table)
2001 Dec 12
2
Output from the multinom-function
Hello folks,
Let me first apologize: I'm not a professional nor a
mathematician, just an ordinary guy, fooling around
with the excellent R-package. I know the basic
principles behind statistics, but haven't read
anything more advanced than the ordinary first
probability and statistics courses.
Enough disclaimers? Good! I was examining the
multinom-function (in the nnet-package) the other
2001 Jun 28
0
: k-fold cross validation for fda,mda etc
Hi all,
Has anyone tried to do k-fold cross validation for flexible discriminant
analysis ( mda library), for example, using crossval() in bootstrap?
The problem is that the function crossval() requires a separate matrix
for predictors and another for responses, whereas the function fda(),
using the formula argument only.
Is there another way of doing k-fold cross validation for functions
which
2005 May 09
1
formula restriction in multinom?
Good Day: When I used:
multinom(formula = Y ~ X1 + X2 + X3 + X1:X2 + X1:X3 + X3:X2 + X1^2 + X2^2 +
X3^2, data = DATASET),
I get estimates and AIC for the model containing main effects and
interactions only (no squared terms)...and FYI, all predictors are
continuous. Is this "normal" behavior? If I run this in S-Plus I get
estimates and AIC for the model containing all terms(including
1999 Aug 24
1
package mlbench updated
Hi,
Evgenia and I have copied an updated version of the mlbench package to
CRAN which contains several new data sets. We have also changed some
of the variable names to avoid name conflicts.
Best,
--
-------------------------------------------------------------------
Friedrich Leisch
Institut f?r Statistik Tel: (+43 1) 58801 10715
Technische
1999 Aug 24
1
package mlbench updated
Hi,
Evgenia and I have copied an updated version of the mlbench package to
CRAN which contains several new data sets. We have also changed some
of the variable names to avoid name conflicts.
Best,
--
-------------------------------------------------------------------
Friedrich Leisch
Institut f?r Statistik Tel: (+43 1) 58801 10715
Technische
2007 Mar 25
2
resolving expand.grid & NA errors
I am hoping for some advice regarding resolving error messages I have
received when trying to use the expand.grid command.
library(nnet)
library(MASS)
library(car)
mod.multacute <-multinom(kc$group ~ kc$in.acute.danger *
kc$violent.convictions, na.rm=T)
summary(mod.multacute, cor=F, Wald=T)
Anova (mod.multacute)
confint (mod.multacute)
> predictors <- expand.grid(group=1:3,