Displaying 20 results from an estimated 600 matches similar to: "glm(y ~ -1 + c, "binomial") question"
2002 Apr 30
1
MemoryProblem in R-1.4.1
Hi all,
In a simulation context, I'm applying some my function, "myfun" say, to a
list of glm obj, "list.glm":
>length(list.glm) #number of samples simulated
[1] 1000
>class(list.glm[[324]]) #any component of the list
[1] "glm" "lm"
>length(list.glm[[290]]$y) #sample size
[1] 1000
Because length(list.glm) and the sample size are rather large,
2004 Aug 19
1
The 'test.terms' argument in 'regTermTest' in package 'survey'
This is a question regarding the 'regTermTest' function in the 'survey' package.  Imagine Z as a three level factor variable, and code ZB and ZC as the two corresponding dummy variables.  X is a continuous variable.  In a 'glm' of Y on Z and X, say, how do the two test specifications
	test.terms = c("ZB:X","ZC:X")  # and
	test.terms = ~ ZB:X + ZC:X
in
2006 Mar 16
2
DIfference between weights options in lm GLm and gls.
Dear R-List users,
Can anyone explain exactly the difference between Weights options in lm glm
and gls?
I try the following codes, but the results are different.
> lm1
Call:
lm(formula = y ~ x)
Coefficients:
(Intercept)            x
     0.1183       7.3075
> lm2
Call:
lm(formula = y ~ x, weights = W)
Coefficients:
(Intercept)            x
    0.04193      7.30660
> lm3
Call:
2006 Aug 31
1
NaN when using dffits, stemming from lm.influence call
Hi all
I'm getting a NaN returned on using dffits, as explained
below.  To me, there seems no obvious (or non-obvious reason
for that matter) reason why a  NaN  appears.
Before I start digging further, can anyone see why  dffits
might be failing?  Is there a problem with the data?
Consider:
# Load data
dep <- 
2003 Feb 28
1
summary.glm() print problem(?) with cor = TRUE
Hi,
I've had a look the bug list and searched though the R documentation, email
lists etc. but didn't see anything on this:
when I do:
summary(species.glm1, correlation = TRUE)
I get a correlation matrix like this:
Correlation of Coefficients:
        ( p I(H C
pH      * 1      
I(pH^2) * B 1    
Ca        . .   1
I(Ca^2)   . .   B
attr(,"legend")
[1] 0 ` ' 0.3 `.'
2013 Jan 06
4
random effects model
Hi A.K
Regarding my question on comparing normal/ obese/overweight with blood
pressure change, I did finally as per the first suggestion of stacking the
data and creating a normal category . This only gives me a obese not obese
14, but when I did with the wide format hoping to  get  a
obese14,normal14,overweight 14 Vs hibp 21, i could not complete any of the
models.
This time I classified obese=1
2008 Oct 15
1
Parameter estimates from an ANCOVA
Hi all,
This is probably going to come off as unnecessary (and show my ignorance)
but I am trying to understand the parameter estimates I am getting from R
when doing an ANCOVA.  Basically, I am accustomed to the estimate for the
categorical variable being equivalent to the respective cell means minus the
grand mean.  I know is the case in JMP - all other estimates from these data
match the
2009 Jun 11
2
How to order an data.table by values of an column?
Hello!
Can you help me? How to order an data.table by values of an column?
Per example:
Table no initial
Categ Perc
468  31.52
351  27.52
0  0.77
234  22.55
117  15.99
table final
Categ Perc
0  0.77
117  15.99
234  22.55
351  27.52
468  31.52
Lesandro
      Veja quais são os assuntos do momento no Yahoo! +Buscados
	[[alternative HTML version deleted]]
2007 May 18
4
Simple programming question
Hi R-users,
I have a simple question for R heavy users. If I have a data frame like this
dfr <- data.frame(id=1:16, categ=rep(LETTERS[1:4], 4),
var3=c(8,7,6,6,5,4,5,4,3,4,3,2,3,2,1,1))
dfr <- dfr[order(dfr$categ),]
and I want to score values or points in variable named "var3" following this
kind of logic:
1. the highest value of var3 within category (variable named
2008 May 08
2
poisson regression with robust error variance ('eyestudy
Ted Harding said:
> I can get the estimated RRs from
> RRs <- exp(summary(GLM)$coef[,1])
> but do not see how to implement confidence intervals based
> on "robust error variances" using the output in GLM.
Thanks for the link to the data.  Here's my best guess.   If you use
the following approach, with the HC0 type of robust standard errors in
the
2008 Nov 19
1
F-Tests in generalized linear mixed models (GLMM)
Hi!
I would like to perform an F-Test over more than one variable within a 
generalized mixed model with Gamma-distribution
and log-link function. For this purpose, I use the package mgcv.
Similar tests may be done using the function "anova", as for example in 
the case of a normal
distributed response. However, if I do so, the error message
"error in eval(expr, envir, enclos) :
2010 Nov 24
2
Is there an equivalent to predict(..., type="linear") of a Proportional hazard model for a Cox model instead?
Hi all,
Is there an equivalent to predict(...,type="linear") of a Proportional hazard 
model for a Cox model instead?
For example, the Figure 13.12 in MASS (p384) is produced by:
(aids.ps <- survreg(Surv(survtime + 0.9, status) ~ state + T.categ + 
pspline(age, df=6), data = Aidsp))
zz <- predict(aids.ps, data.frame(state = factor(rep("NSW", 83), levels = 
2009 Feb 16
1
Overdispersion with binomial distribution
I am attempting to run a glm with a binomial model to analyze proportion
data.
I have been following Crawley's book closely and am wondering if there is
an accepted standard for how much is too much overdispersion? (e.g. change
in AIC has an accepted standard of 2).
In the example, he fits several models, binomial and quasibinomial and then
accepts the quasibinomial.
The output for residual
2011 Sep 21
1
Problem with predict and lines in plotting binomial glm
Problems with predict and lines in plotting binomial glm
Dear R-helpers
I have found quite a lot of tips on how to work with glm through this mailing list, but still have a problem that I can't solve.
I have got a data set of which the x-variable is count data and the y-variable is proportional data, and I want to know what the relationship between the variables are.
The data was
2011 Jun 23
2
Rms package - problems with fit.mult.impute
Hi!
Does anyone know how to do the test for goodness of fit of a logistic model (in rms package) after running fit.mult.impute?
I am using the rms and Hmisc packages to do a multiple imputation followed by a logistic regression model using lrm.
Everything works fine until I try to run the test for goodness of fit: residuals(type=c("gof"))
One needs to specify y=T and x=T in the fit. But
2002 Jan 02
0
comparative rendering of modeling outputs
This note is to r-devel rather than r-announce because it
notes an experimental package that addresses issues that 
intersect with broader developmental issues in R.
I have posted the package
cremo = Comparative REndering of Modeling Outputs
for retrival at
http://www.biostat.harvard.edu/~carey/cremo.html
This package addresses the problem of assembling and
rendering results of multiple
2007 Feb 14
1
how to report logistic regression results
Dear all,
I am comparing logistic regression models to evaluate if one predictor
explains additional variance that is not yet explained by another predictor.
As far as I understand Baron and Li describe how to do this, but my question
is now: how do I report this in an article? Can anyone recommend a
particular article that shows a concrete example of how the results from te
following simple
2010 Jun 03
1
compare results of glms
dear list!
i have run several glm analysises to estimate a mean rate of dung decay 
for independent trials. i would like to compare these results 
statistically but can't find any solution. the glm calls are:
dung.glm1<-glm(STATE~DAYS, data=o_cov, family="binomial(link="logit"))
dung.glm2<-glm(STATE~DAYS, data=o_cov_T12, family="binomial(link="logit"))
as
2011 Aug 28
1
Trying to extract probabilities in CARET (caret) package with a glmStepAIC model
Dear developers,
I have jutst started working with caret and all the nice features it offers. But I just encountered a problem:
I am working with a dataset that include 4 predictor variables in Descr and a two-category outcome in Categ (codified as a factor).
Everything was working fine I got the results, confussion matrix etc.
BUT for obtaining the AUC and predicted probabilities I had to add
2004 May 07
1
contrasts in a type III anova
Hello,
I use a type III anova ("car" package) to analyse an unbalanced data design. I 
have two factors and I would have the effect of the interaction. I read that 
the result could be strongly influenced by the contrasts. I am really not an 
expert and I am not sure to understand indeed about what it is...
Consequently, I failed to properly used the fit.contrast function (gregmisc