Displaying 20 results from an estimated 20000 matches similar to: "stepAIC"
2006 Dec 04
1
stepAIC for lmer
Dear All,
I am trying to use stepAIC for an lmer object but it doesn't work. Here is an example:
x1 <- gl(4,100)
x2 <- gl(2,200)
time <- rep(1:4,100)
ID <- rep(1:100, each=4)
Y <- runif(400) <=.5
levels(Y) <- c(1,0)
dfr <- as.data.frame(cbind(ID,Y,time,x1,x2))
fm0.lmer <- lmer(Y ~ time+x1+x2 + (1|ID), data = dfr, family = binomial)
2009 May 05
2
Stepwise logistic Regression with significance testing - stepAIC
Hello R-Users,
I have one binary dependent variable and a set of independent variables (glm(formula,…,family=”binomial”) ) and I am using the function stepAIC (“MASS”) for choosing an optimal model. However I am not sure if stepAIC considers significance properties like Likelihood ratio test and Wald test (see example below).
> y <- rbinom(30,1,0.4)
> x1 <- rnorm(30)
> x2
2000 Jul 21
1
confint() error
Dear all,
I have run the confint() function according to below and I get the
following error message:
> confint(stepAIC.glm.spe.var.konn2.abund, level=0.95)
Waiting for profiling to be done...
Error: missing value where logical needed
In addition: Warning message:
NaNs produced in: sqrt((fm$deviance - OriginalDeviance)/DispersionParameter)
or
> confint(stepAIC.glm.spe.var.konn2.abund,
2012 Nov 02
0
stepAIC and AIC question
I have a question about stepAIC and extractAIC and why they can
produce different answers.
Here's a stepAIC result (slightly edited - I removed the warning
about noninteger #successes):
stepAIC(glm(formula = (Morbid_70_79/Present_70_79) ~ 1 + Cohort +
Cohort2, family = binomial, data = ghs_70_79, subset =
ghs_70_full),direction = c("backward"))
Start: AIC=3151.41
2011 Nov 29
0
Any function\method to use automatically Final Model after bootstrapping using boot.stepAIC()
Hi List,
Being new to R, I am trying to apply boot.stepAIC() for Model selection by
bootstrapping the stepAIC() procedure. I had gone through the discussion in
various thread on the variable selection methods. Understood the pros and
cons of various method, also going through the regression modelling
strategies in rms.
I want to read Final model or Formula or list of variables automatically
2006 May 05
1
trouble with step() and stepAIC() selecting the best model
Hello,
I have some trouble using step() and stepAIC() functions.
I'm predicting recruitment against several factors for different plant
species using a negative binomial glm.
Sometimes, summary(step(model)) or summary(stepAIC(model) does not
select the best model (lowest AIC) but just stops before.
For some species, step() works and stepAIC don't and in others, it's the
opposite.
2002 Apr 01
0
something confusing about stepAIC
Folks, I'm using stepAIC(MASS) to do some automated, exploratory, model
selection for binomial and Poisson glm models in R 1.3. Because I wanted to
experiment with the small-sample correction AICc, I dug around in the code
for the functions
glm.fit
stepAIC
dropterm.glm
addterm.glm
extractAIC.glm
and came across something I just don't understand.
stepAIC() passes dropterm.glm() a
2009 Feb 18
1
using stepAIC with negative binomial regression - error message help
Dear List,
I am having problems running stepAIC with a negative binomial regression model. I am working with data on manta ray abundance, using 20 predictor variables. Predictors include variables for location (site), time (year, cos and sin of calendar day, length of day, percent lunar illumination), oceanography (sea surface temp mean and std, sea surface height mean and std), weather (cos
2009 Jul 10
1
generalized linear model (glm) and "stepAIC"
Hi,
I'm a very new user of R and I hope not to be too "basic" (I tried to
find the answer to my questions by other ways but I was not able to).
I have 12 response variables (species growth rates) and two
environmental factors that I want to test to find out a possible
relation.
The sample size is quite small: (7<n<12, depending on each species-case).
I performed a
2009 Jan 26
1
glm StepAIC with all interactions and update to remove a term vs. glm specifying all but a few terms and stepAIC
Problem:
I am sorting through model selection process for first time and want to make
sure that I have used glm, stepAIC, and update correctly. Something is
strange because I get a different result between:
1) a glm of 12 predictor variables followed by a stepAIC where all
interactions are considered and then an update to remove one specific
interaction.
vs.
2) entering all the terms
2008 May 09
2
How can one make stepAIC and lme
Dear R-help
I'm working on a large dataset which I have divided into 20 subsets based on similar features. Each subset consists of observations from different locations and I wish to use the location as a random effect.
For each group I want to select regressors by a stepwise procedure and include a random effect on the intercept. I use stepAIC() and lme(). (The lmer()-function doesn't
2004 Jun 01
2
GLMM(..., family=binomial(link="cloglog"))?
I'm having trouble using binomial(link="cloglog") with GLMM in
lme4, Version: 0.5-2, Date: 2004/03/11. The example in the Help file
works fine, even simplified as follows:
fm0 <- GLMM(immun~1, data=guImmun, family=binomial, random=~1|comm)
However, for another application, I need binomial(link="cloglog"),
and this generates an error for me:
>
2005 Nov 02
1
nlminb failed to converge with lmer
Dear all,
I'm building binomial mixed-model using lme4 package.
I'm able to obtain outputs properly except when I include two particular
variables: date (from 23 to 34; 1 being to first sampling day) and Latitude
(UTM/100 000, from 55.42 to 56.53). No "NA" is any of those variables.
In those cases, I get the warning message: "nlminb failed to converge"
I tried to
2004 Dec 31
4
R-intro
Hello!
I was reading R-intro and I have some suggestions:
R-intro.html#A-sample-session
rm(fm, fm1, lrf, x, dummy)
suggestion
rm(fm, fm1, lrf, x, y, w, dummy)
The next section will look at data from the classical experiment of Michaelson and Morley to measure the speed of light.
file.show("morley.tab")
mm <- read.table("morley.tab")
suggestion
mm <- data(morley)
2010 Jul 07
1
Why do <none>s appear in the list of predictor variables in logistic regression using 'step' or 'stepAIC' function?
Would anyone help me solve my problem with R, please? I am very new to R. I am doing logistic regression analysis on the presence/absence of salamanders using several predictor variables, as shown below. I have checked my data, but I didn't find any 'NA' or empty cells. When I used step() or stepAIC to select significant predictor variables, <none>s appear to places where
2007 Feb 07
3
generate Binomial (not Binary) data
Dear All,
I am looking for an R function or any other reference to generate a series of correlated Binomial (not a Bernoulli) data. The "bindata" library can do this for the binary not the binomial case.
Thank you,
Bernard
---------------------------------
[[alternative HTML version deleted]]
2006 Nov 22
2
help
consider p as random effect with 5 levels, what is difference between these
two models?
> p5.random.p <- lmer(Y
~p+(1|p),data=p5,family=binomial,control=list(usePQL=FALSE,msV=1))
> p5.random.p1 <- lmer(Y
~1+(1|p),data=p5,family=binomial,control=list(usePQL=FALSE,msV=1))
thanks,
Aimin Yan
2003 Jul 30
0
stepAIC()
Hi,
I am experiencing a baffling behaviour of stepAIC(),
and I hope to get any advice/help on this. Greatly
appreciate any kind advice given.
I am using stepAIC() to, say, select a model via
stepwise selection method.
R Version : 1.7.1
Windows ME
Many thanks!
***Issue :
When stepAIC() is placed within a function, it seems
that stepAIC() cannot detect the data matrix, and the
program is
2003 Aug 04
1
Error in calling stepAIC() from within a function
Hi,
I am experiencing a baffling behaviour of stepAIC(),
and I hope to get any advice/help on what went wrong
or I'd missed. I greatly appreciate any advice given.
I am using stepAIC() to, say, select a model via
stepwise selection method.
R Version : 1.7.1
Windows ME
Many thanks and best regards,
Siew-Leng
***Issue :
When stepAIC() is placed within a function, it seems
2002 Jun 08
3
contour plot for non-linear models
Hello all,
I've tried to reproduce the contour plot that appears in the book of
Venables and Ripley, at page 255. Is a F-statistic surface and a
confidence region for the regression parameters of a non-linear model.
It uses the stormer data that are in the MASS package.
I haven't been able to reproduce the plot either in R ( version 1.5 )
and S. It makes the axes and it puts the