similar to: glm() functions

Displaying 20 results from an estimated 30000 matches similar to: "glm() functions"

2000 Mar 28
2
Logistic ridge regression ...
Hi I have some data (v. large amount) with a (0,1) response where I want to minimise the errors in the betas rather than SS or deviance. So can anyone point me to a ridge regression function or equivalent for such a logistic regression case? John -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read
2011 Nov 20
3
logistic regression by glm
HI I use glm in R to do logistic regression. and treat both response and predictor as factor In my first try: ******************************************************************************* Call: glm(formula = as.factor(diagnostic) ~ as.factor(7161521) + as.factor(2281517), family = binomial()) Deviance Residuals: Min 1Q Median 3Q Max -1.5370 -1.0431 -0.9416 1.3065 1.4331 Coefficients:
2012 Mar 03
1
interpreting the output of a glm with an ordered categorical predictor.
Greetings. I'm a Master's student working on an analysis of herbivore damage on plants. I have a tried running a glm with one categorical predictor (aphid abundance) and a binomial response (presence/absence of herbivore damage). My predictor has four categories: high, medium, low, and none. I used the "ordered" function to sort my categories for a glm. ah <-
2010 Oct 04
2
Plot for Binomial GLM
Hi i would like to use some graphs or tables to explore the data and make some sensible guesses of what to expect to see in a glm model to assess if toxin concentration and sex have a relationship with the kill rate of rats. But i cant seem to work it out as i have two predictor variables~help?Thanks.:) Here's my data. >
2006 Jan 15
1
problems with glm
Dear R users, I am having some problems with glm. The first is an error message "subscript out of bounds". The second is the fact that reasonable starting values are not accepted by the function. To be more specific, here is an example: > success <- c(13,12,11,14,14,11,13,11,12) > failure <- c(0,0,0,0,0,0,0,2,2) > predictor <- c(0,80*5^(0:7)) >
2012 May 07
1
Can't find the error in a Binomial GLM I am doing, please help
Hi all, I can't find the error in the binomial GLM I have done. I want to use that because there are more than one explanatory variables (all categorical) and a binary response variable. This is how my data set looks like: > str(data) 'data.frame': 1004 obs. of 5 variables: $ site : int 0 0 0 0 0 0 0 0 0 0 ... $ sex : Factor w/ 2 levels "0","1": NA NA NA
2005 Nov 08
1
Interpretation of output from glm
I am fitting a logistic model to binary data. The response variable is a factor (0 or 1) and all predictors are continuous variables. The main predictor is LT (I expect a logistic relation between LT and the probability of being mature) and the other are variables I expect to modify this relation. I want to test if all predictors contribute significantly for the fit or not I fit the full
1999 Mar 02
1
Can't understand error message :-{
I'm sorry if this is a basic question, but I'm stumped. I'm just trying to plot the residuals from a linear model against another variable in the data frame. Here are the lines I'm trying to execute: size <- read.table(file="/u67/abasl70/surveys/annenberg/mega/smschl.dat", header=T) sizef <- data.frame(size, row.names=size$unit) attach(sizef) mschmod <- lm
2012 Apr 09
2
Overall model significance for poisson GLM
Greetings, I am running glm models for species counts using a poisson link function. Normal summary functions for this provide summary statistics in the form of the deviance, AIC, and p-values for individual predictors. I would like to obtain the p-value for the overall model. So far, I have been using an analysis of deviance table to check a model against the null model with the intercept as
2018 Jun 03
2
aic() component in GLM-family objects
Is it generally known/has it been previously discussed here that the $aic() component in GLM-family objects (e.g. results of binomial(), poisson(), etc.) does not as implemented actually return the AIC, but rather -2*log-likelihood + 2*(model_has_scale_parameter) ? Can anyone in this forum gauge how a documentation patch would be received? This behaviour does not seem to be documented in ?family
2012 Sep 29
1
Unexpected behavior with weights in binomial glm()
Hi useRs, I'm experiencing something quite weird with glm() and weights, and maybe someone can explain what I'm doing wrong. I have a dataset where each row represents a single case, and I run glm(...,family="binomial") and get my coefficients. However, some of my cases have the exact same values for predictor variables, so I should be able to aggregate up my data frame and
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
2006 Mar 27
1
Glm poisson
Hello, I am using the glm model with a poisson distribution. The model runs just fine but when I try to get the null deviance for the model of the null degrees of freedom I get the following errors: > null.deviance(pAmeir_1) Error: couldn't find function "null.deviance" > df.null(pAmeir_1) Error: couldn't find function "df.null" When I do: >
2012 Nov 27
1
glm convergence warning
Hello, When I run the following glm model: modelresult=glm(CID~WS+SS+DV+DS, data=kimu, family=binomial) I get the following warning messages: 1: glm.fit: algorithm did not converge 2: glm.fit: fitted probabilities numerically 0 or 1 occurred What I am trying to do is model my response variable (CID: correct bird identification) as a function of the predictor variables weather state (WS), sea
2008 Nov 12
1
Understanding glm family documentation: dev.resids
Hi all Consider the family function, as used by glm. The help page says the value of the family object is a list, one element of which is the following: dev.resids function giving the deviance residuals as a function of (y, mu, wt). But reading any of the family functions (eg poisson) shows that dev.resids is a function that computes the *square* of the deviance residuals (at least, by
2005 Jun 16
1
mu^2(1-mu)^2 variance function for GLM
Dear list, I'm trying to mimic the analysis of Wedderburn (1974) as cited by McCullagh and Nelder (1989) on p.328-332. This is the leaf-blotch on barley example, and the data is available in the `faraway' package. Wedderburn suggested using the variance function mu^2(1-mu)^2. This variance function isn't readily available in R's `quasi' family object, but it seems to me
2010 Jul 09
1
Appropriate tests for logistic regression with a continuous predictor variable and Bernoulli response variable
I have a data with binary response variable, repcnd (pregnant or not) and one predictor continuous variable, svl (body size) as shown below. I did Hosmer-Lemeshow test as a goodness of fit (as suggested by a kind “R-helper” previously). To test whether the predictor (svl, or body size) has significant effect on predicting whether or not a female snake is pregnant, I used the differences between
2011 Jun 13
1
glm with binomial errors - problem with overdispersion
Dear all, I am new to R and my question may be trivial to you... I am doing a GLM with binomial errors to compare proportions of species in different categories of seed sizes (4 categories) between 2 sites. In the model summary the residual deviance is much higher than the degree of freedom (Residual deviance: 153.74 on 4 degrees of freedom) and even after correcting for overdispersion by
2013 Jan 31
2
glm poisson and quasipoisson
Hello, I have a question about modelling via glm. I have a dataset (see dput) that looks like as if it where poisson distributed (actually I would appreciate that) but it isnt because mean unequals var. > mean (x) [1] 901.7827 > var (x) [1] 132439.3 Anyway, I tried to model it via poisson and quasipoisson. Actually, just to get an impression how glm works. But I dont know how to
2020 Sep 14
3
Interpretación de salida de un GLM
Estimada comunidad, tengo unas dudas que son muy básicas creo, pero es mi primera incursión en GLM. Estoy ajustando un modelo binomial a unos datos de germinación. El modelo es muy sencillo, tengo un factor "Condicion" con dos niveles: "a" y "b" (nivel de humedad en suelo). Por otro lado, tengo una variable explicativa "HF" (horas frío=estratificación) que