A generalization of linear regression allowing for nonlinear relationships via a "link function" and for the variance of the response to depend on the predicted value. (Not to be confused with "general linear model" which extends the ordinary linear model to general covariance structure and ...

learn more… | top users | synonyms (1)

0
votes
1answer
16 views

Can we write the likelihood of a GLM in generality?

So I know we can explicitly write down the likelihood of any specified GLM model, for example the likelihood for the logistic regression model would be ...
1
vote
1answer
39 views

glm model fit - can't find a family/link combination that produces good fit

I am having difficulty finding a correct glm model to fit my data. The outcome is the length of time in months a person will spend in prison (sentence length). It's technically a count, all positive ...
0
votes
0answers
23 views

How to find marginal effects and test if they are significant in Eviews

Say I have a regression which gives the output income = 4.365*age - 0.092*(age)^2 + 0.866*years_of_education How would I work out the marginal effect for a ...
1
vote
0answers
23 views

Discrepancy between logistic regression and logistic regression results?

Suppose I have a data set of 200 controls (group A; has no memory problems) and 100 cases (group B; has memory problems). And I'm looking at the relationship between memory and cognitive test score ...
0
votes
0answers
43 views
+100

What's the right interpretation for parameter estimates in loglinear modelling?

I'm doing a loglinear analysis of the following data. Male is coded as 1, Female as 2. Senior workers are coded as 1, middle level as 2, and shopfloor as 3. A is coded as 1 and is the most ...
0
votes
0answers
17 views

Poisson/Negative Binomial/Gamma log-link for continuous dependent variable (scale DV)

In my research about sport injuries in football, I am trying to obtain Incidence Rate Ratios (IRR) comparing my categories with the reference category. I have number of days a player was absent due to ...
2
votes
1answer
33 views

Model to predict categorical outcome from continuous and categorical variables

I have to fit a model to test whether Learning (1=learned, 0=failed) depends on lizard sex (M or F), Lizard SVL (snout-vent length), or an interaction of the two. I am new to both R and this website. ...
2
votes
1answer
44 views

Best way to deal with heteroscedasticity in R?

Originally posted on stackexchange but I was told that it fits better here. I have a plot of residual values of a linear model in function of the fitted values where the heteroscedasticity is very ...
1
vote
0answers
28 views

Best way to deal with heteroscedasticity in R?

I have a plot of residual values of a linear model in function of the fitted values where the heteroscedasticity is very clear. However I'm not sure how I should proceed now because as far as I ...
1
vote
0answers
18 views

How to model the following dependent variable? [closed]

If I got a dataset which the (count data) dependent variable has the following distribution, how should I model it? I am aware of the zero inflated model and the negative binomial model, but are ...
0
votes
0answers
14 views

“Factorial” Profile Analysis, does it exist? Or is there maybe a better statistical method I should be using?

I am working on a visual search project that I created in Psychtoolbox with Matlab. As with most visual search studies, there will be within subjects tests, since each subject completes many trials. ...
2
votes
1answer
35 views

Exploring effect of treatment on count data

I've collected data on animal visitation at four different points in time. The four time points represent the total animal visitations over a three day period, i.e. 3 days of monitoring at four ...
0
votes
0answers
19 views

interpretation of coefficients from glm model, normal family with log link vs. linear model with logged outcome

I was fitting a linear model where the outcome was log transformed. The outcome is overdispersed and skewed and logging dramatically improved model fit. For reasons that relate to the software ...
1
vote
0answers
17 views

Intuitive explanation of failed convergence for GLM

Sometimes the software complains about some matrix not being positive definite. Is it the singularity that's causing issues (because the iterative algorithm involves inverting matrices)? Also, what ...
0
votes
1answer
23 views

I need a matrix in order to calculate g-inverse of it [closed]

I want to calculate g-inverse of a matrix, which has 4 rows and not a square matrix and has no inverse. Please help me find such a sound (good) matrix. I only need a matrix. You can suggest a book or ...
2
votes
1answer
163 views

How to implement GLM computationally in C++ (or other languages)? [closed]

I want to implement the GLM model in C++ for a commercial package (ie. this is not for fun), including but not limited to normal, binomial distribution etc. I'm not so sure how the implementation ...
1
vote
0answers
15 views

truncated binomial samples with GLM

We have a binomial process that yields samples of 60 trials. To save time, once 2 failures have been observed the process is reset. So if a test series hits 2 failures early, the resultant sample ...
1
vote
1answer
43 views

GLM Interaction Lasso

Apparently the stepwise produce in R is not a good way to automatically select the best glm model. Different sources suggest using lasso instead. I had a look at the glmnet packages but I do not ...
1
vote
0answers
13 views

Lambda's from glmnet (R) used in online SGD [migrated]

I'm using cv.glmnet from glmnet package (in R). In the outcome I get a vector of ...
0
votes
1answer
24 views

R Linear model step NA values

My aim is to carry out a generalized linear model (glm) with 1 response variable and 13 explanatory variables.Unfortunately 3 out of the 10 explanatory variables contain NA values (2/3 of data set of ...
1
vote
0answers
29 views

R Linear model step NA values

My aim is to carry out a generalized linear model (glm) with 1 response variable and 13 explanatory variables.Unfortunately 3 out of the 10 explanatory variables contain NA values (2/3 of data set of ...
0
votes
0answers
18 views

Using QIC in glm (geeglm) when there is a warning of glm.fit: fitted probabilities numerically 0 or 1 occurred

I am using geepack in R to look for the best model for my data. I run the gee function with family=binomial(link="logit"). From the results I use QIC to find the ...
3
votes
0answers
20 views

Appropriate test (in R) for proportion data that aren't normally distributed, aren't based on counts, and include 0's and 1's?

I'm studying differences in tree health among 5 species of trees across 3 different green infrastructure types. Here are the first few lines of data: ...
0
votes
0answers
9 views

Estimating Risk (OR) for a Cohort over time

I am trying to assess the changing risk (OR) of group A relative to group B over time adjusting for a number of covariates. One approach I have attempted is to split the data set using a monthly ...
2
votes
1answer
29 views

Zero-inflated gamma - how to write down the cdf?

My goal is building a predictive model to give probabilistic forecasts. My response variable has lots of zeros but otherwise looks close to a gamma. I fit the whole dataset using some classification ...
0
votes
0answers
22 views

How to interpret parameters of GLM with binomial family for proportions

I would like to use glm with binomial family for proportions. However, I am wondering how could I interpret the parameters that is important in my case. In binary logistic regression one can interpret ...
0
votes
0answers
19 views

How to use GLM to decide between three factors based on binary data?

I have some problems with the interpretation of my glm results. I measured the disturbance of differently cultivated/ used site on a binary scale. 1 being influenced by the land use and 0 being not ...
0
votes
0answers
18 views

“fitted probabilities numerically 0 or 1 occurred ” in R? [duplicate]

I am trying to build a logistic regression that would tell me if it's worth sending a letter to a client. I have 11 significant variables in the model: What can I do to eliminate the warning ...
1
vote
0answers
8 views

Slope testing for regression lines between non-normal explanatory and response variables

I would like to estimate a regression line between my explanatory and response variables. The explanatory and the response variables are (paired) instrumental measures of the same thing under ...
0
votes
0answers
13 views

Robglm warning: 'algorithm did not converge'

I am trying to perform a bootstrapped robust GLM, but for some of the replications I get the warning: 'algorithm did not converge'. I use the triangular dataset below, where each row represents an ...
0
votes
0answers
16 views

I can't get my head around how to fix coefficient 1 not defined because of singularities problem

I am trying to use a GLM to test whether groupsize affects the frequency of butting in termites, I have non-normal data and I want to see if average weight of the termite has a random affect on the ...
1
vote
0answers
6 views

Skewed response variable LM [duplicate]

I have a positive asymmetric response variable in a regression model. One of the assumptions about linear model is that the stochastic component of the model is normally distributed. If I have a ...
0
votes
0answers
18 views

Generalized linear model Gaussian distribution Linear Model

Is a generalized linear model with a Gaussian distribution the same as a linear model?
3
votes
1answer
151 views

Overdispersion in GLM with Gaussian distribution

To check for overdispersion in GLM with a Poisson distribution one can compare the residual deviance with the residual degrees of freedom. If they are equal the Poisson error assumption is appropriate ...
1
vote
0answers
13 views

How a tweedie glm handles an offset?

I am trying to fit a model with a glm using a tweedie family. I use a index parameter p between 1 and 2 to get a compound Poisson Gamma distribution to fit my data. But I want to use an offset only on ...
0
votes
0answers
20 views

random effect for mixed model

I have ran mixed model with random effect. I have design 4 models iteratively following Zuur et al. the simplest one, and then I have added the other main and interaction effect (all with 1|subject as ...
0
votes
1answer
27 views

Tree model with poisson distributed response variable

If I understand correctly the R tree model - library(tree) - can only be used if the response variable is normally distributed. Is there a way to create a tree model with poisson distributed response ...
0
votes
0answers
16 views

Mechanics of converting success/failure values to logit in glm?

While I am reasonably comfortable with performing and interpreting the output from logistic regression using glm in R, I had a question about the mechanics of the calculation to better understand what ...
1
vote
0answers
49 views

What is the difference between lm(log(y) ~ x) and glm(y ~ x, family = gaussian(link = “log”))? [duplicate]

Is all in the title. I would like to know if there is any difference in terms of coefficients, residuals, p-values, but also conceptually.
0
votes
1answer
25 views

perfect variable separation, determine cutoff via ROCR package in R

I am developing a logistic regression model where perfect variable separation occurs. I want to calculate a cutoff from this data. Interestingly, the length of the slot ...
0
votes
0answers
20 views

Proper Model Selection Randomized Block with Count Data

I have a data set on insect counts that looks like this: ...
0
votes
1answer
26 views

Generalized linear model with random effects for skewed data

I'd like to use SPSS Generalized Linear Model to analyze a dataset of insects collected from one particular species of vegetables. I have following variables: NUMBER (number of insects collected) ...
1
vote
0answers
25 views

Relationship between the parameters of the Normal distribution and parameters in the probit with multiple predictors?

According to A. Agresti (2007, p. 73) in binary probit regression: "The parameters of the normal distribution relate to the parameters in the probit by mean (mu = -alpha/beta) and standard deviation ...
2
votes
1answer
23 views

Weighted GLM without weights

Suppose we have at our disposal a glm() that's got all the typical features except the ability to specify weights. Intuitively, I can trick it into using weights ...
1
vote
1answer
28 views

Difference between multilevel GLM and mixed linear models when the family is Gaussian and link function is Identity?

In Stata 13, there is now the new command "meglm" (multilevel generalized linear models) to analyse hierarchical models. My question is, what is the difference between the "meglm" with family of ...
2
votes
1answer
43 views

Appropriate regression-like model where the response is on half-integers

What is an appropriate model for the above scatter plot? I am not fully satisfied with a simple linear regression model. Any suggestions? Y in this problem is discrete in nature. It only increments ...
1
vote
0answers
53 views

Fitting GLM with Quasi-Newton method

I'm trying to code my own quasi-Newton algorithm for fitting GLMs in R. My results do not match up with glm and I've been over my code many, many times so I'm ...
1
vote
1answer
23 views

Can two separate regression coefficients be added to estimate their mutual effect?

Let's say I perform a Cox regression including 3 predictors that relate to the survival: Hazard ratios (HR) for predictors Sex: Hazard ratio for males = HR 1.5 Treatment: Hazard ratio for being ...
3
votes
1answer
59 views

Estimates of random effects in binomial model (lme4)

I'm simulating Bernoulli trials with a random $\text{logit}\, \theta \sim {\cal N}(\text{logit}\, \theta_0, 1^2)$ between groups and then I fit the corresponding model with the ...