Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [generalized-linear-model]

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 multivariate response.)

0
votes
0answers
13 views

Generalized estimation equation distribution and link

Please fill me in. Thank you in advance. I have 3 response variables, 2 of them are positively skewed and have a continuous positive value while the rest is negatively skewed and have a continuous ...
1
vote
0answers
9 views

Regression and Covariance Parameter Matrices in Multiresponse Gaussian Regression Using glmnet (R)? [on hold]

I am new to using glmnet. How do you extract the estimated (sparse) regression and covariance parameter matrices in multiresponse gaussian regression using the glmnet package? There doesn't seem to be ...
0
votes
0answers
10 views

GLM errors: no valid set of coefficients and In log(ifelse(y==0,1,y/mu)):NaNs produced

I am trying to determine which variables influence my response variable droms for individual lizards in 6 sites across 6 years. I am using a glm as my response ...
1
vote
0answers
12 views

How does one compare two nested quasibinomial GLMs?

Lets say I have two models: Model 1 and Model 2, both of which are used to fit a quasibinomial GLM on some 0/1 response data (that I believe has overdispersion, hence quasibinomial GLM instead of ...
2
votes
2answers
50 views

Appropriate model choice for analyzing a cluster based longitudinal randomized controlled trial

I am performing a randomized controlled trial (RCT) of an educational intervention to improve knowledge, belief and practice among healthcare workers in hospitals. One hospital is assigned to the ...
2
votes
0answers
31 views

GLM and saturated models: how do we justify the relation $\hat{\mu}_{i} = y_{i}$?

Given the saturated generalized linear model $g(\mu) = \eta = \textbf{X}\beta$, where the number of parameters equals the number of observations, why do we have $\hat{\mu}_{i} = y_{i}$? Let's us take ...
3
votes
0answers
41 views

What useful properties does the canonical link function have?

So here I am studying generalized linear models. I know this question is quite naive and simple, but I do not exactly know why the link canonical function is so useful. Could someone provide me an ...
3
votes
0answers
17 views

Interpreting contradictory goodness of fit

I am studying the effect of categorical indepdent variables on a binary outcome. To do this, I have fitted a glm as following : ...
0
votes
2answers
41 views

Is the zero truncated Poisson Distribution part of the Exponential Family? [duplicate]

This is the density of a truncated Poisson: $$P(X = x \mid X > 0) = \frac{\lambda ^ x e^{- \lambda} }{x ! \left ( 1 - e^{- \lambda} \right )}$$ To show that it's member of the Exponential ...
0
votes
0answers
8 views

spss GLM AIC and BIC

I have a dataset which contains categorical and numerical predictors, and a binary logistic response. I need to select a best binary logistic model, and to achieve this I use function "Generalised ...
1
vote
0answers
18 views

Partial Collinearity in Regression

I had a doubt about the effect of multi-colinearity in regression analysis. I understand if two variables are co-related we cannot disentangle the effects of one from the other on the target variable ...
2
votes
0answers
12 views

Likelihood ratio tests for quasi- models

I have been playing around with over-dispersion in binomial data and looking into qausi-binomial models as a solution. When comparing binomial models through the change in deviance, I can reproduce ...
0
votes
1answer
31 views

Model validation in R - Gamma GLMM

I'm trying to model a response variable y with respect to a nested variable x in R. First of all, I fitted a linear mixed model (LMM) as it follows: ...
0
votes
0answers
8 views

Zero-inflated model with no variation in the outcome

I want to fit a zero-inflated neg. binomial model using zeronfl(outcol ~ vm + Thursday + Saturday |Saturday + Thursday + vm, data, family="negbin") from the pscl ...
0
votes
0answers
8 views

Trouble interpreting GLM Quasi-poisson

I'm doing a count model on the rate of exonerations over prison admissions before and after 1992. I understand that Year > 1992 is the change in intercept post-...
0
votes
0answers
16 views

glm with continuous dependent variable and integer (count) independent variable [closed]

I'm stuck with this issue: I'm trying to test the relation between weight and parasites load and sampling site in my mussels individuals. Thus, the dependent variable is continuous (weight) and the ...
-1
votes
0answers
24 views

How to determine which variables are statistically insignificant in multiple regression?

Currently, I am using R to analyze data. The data has 5 columns to it (glucose, glucose tolerance, insulin, insulin resistance, presence of diabetes(yes or no), presence of diabetes in numerical value(...
1
vote
0answers
17 views

Why $E[y|x;\theta]$ can be thought as $h_\theta (x)$, the hypothesis, in Generalized Linear Model?

I am learning Standford CS229 lecture note1. In 9 Constructing GLMs part, To derive a GLM for this problem, we will make the following three assumptions about the conditional distribution of $y$ ...
3
votes
2answers
91 views

Suggestions on Modeling Approach to Model Percent Complete of a Task

I am trying to predict what percentage (or proportion) of a task is completed by various workers, given the time left until the deadline to complete the task and I'm looking for help on how to ...
2
votes
1answer
19 views

How to treat block (IV) in glm?

I have a word learning experiment in which I am measuring accuracy on a 2AFC task. So, my DV is binary (1=correct, 0=incorrect). As IVs I have ...
0
votes
0answers
15 views

How to do when both response and covariates are missing?

I have some sort of longitudinal data and want to do regression analysis. The problem is that there are missing data both in response variable(y) and covariates(X). (sometimes only y observed, ...
0
votes
0answers
46 views

Which model should I use? (genomic problem)

I have problems with choosing which model / link function should I use for my analysis. My response: numbers from -100% to +500% (increase of tumor after therapy, may switch to ratios or log-ratios, ...
0
votes
0answers
27 views

Binomial distribution in exponential form

I am trying to find out if I am doing this right: I have started with: $f(y)=\binom{n}{y}(\frac{\mu}{n})^y(1-\frac{\mu}{n})^{n-y}$ This is what I get: Result: $exp[ylog(\frac{\mu}{n-\mu}) - nlog(1+e^...
0
votes
1answer
44 views

How should I model this data?

I need to use R studio to model the following problem: According to the Independent newspaper (London, March 8, 1994), the Metropolitan Police in London reported 30,475 people as missing in the year ...
0
votes
0answers
8 views

Performing a GAM with correct error distribution and smoothing functions

I'm applying a GAM from package mgcv using two continuous explanatory variables with a binomial response. What would be the best error distribution to use (Family and link)?
4
votes
2answers
174 views

GLM: Modelling proportional data - account for variation in total sample size

When I am sampling the proportion of a sub-group of animals to the total number of animals within a sample, I can feel quite confident (after taking into account environmental factors) that I have a ...
0
votes
1answer
23 views

Alternative to GLM with non-independant observation

I would like to perform a regression to study association between 3 categorical variables and a presence/absence response variable. I was planning on using a GLM. However, my observation unit being ...
1
vote
1answer
32 views

Binary classification for imbalanced distribution of target/response class for age

I'm trying to build/train model that depends on many attributes where age is the most important one (it has significant impact on AUC). Overall target class count is quite balanced (+40% vs. -60%) ...
0
votes
0answers
38 views

Understanding the DLM

The DLM model in my notes is described as: $f_k(\theta,u)=F_k\theta+u$ and $h_k(\theta,v)=H_k\theta+v$, where $F_k$ is a $d\times d$ matrix and $H_k$ is a $d'\times d$ matrix, respectively called ...
0
votes
0answers
17 views

confused about effects vs. means parameterization in R - which is right for Anova?

I'm running a few GLMs and using the effects (e.g. glm(var1~var2...) ) and then means parameterization (i.e. glm(var1~-1+var2...) -- the one without the intercept). I understand that effects gives you ...
0
votes
1answer
31 views

Why does LASSO ignore a predictor that has predicting power and NOT correlated with other predictors?

I have a linear regression problem for my car fleet data, where $y$ is the change in rental price and $X$ is a design matrix with around 30 columns (predictors). Most of the predictors are continuous ...
1
vote
0answers
23 views

Preparing a GLM logistic regression: choosing the factors

I am researching the incidence of pain after an operation, according to anaesthetic type. Univariate analysis is inconclusive, but I would like to proceed to multivariate analysis. I have done some ...
0
votes
1answer
26 views

Do we need a reference dummy variable for non-mutually exclusive groups?

I am trying to build a GLMM and have converted a group of factors to dummy variables. Many have multiple groups and I would like to test the interactions between them as well. Do I need a reference ...
0
votes
0answers
21 views

goodness-of-fit for logistic regression with a ratio dependent variable

My dependent variable is number of days in a week a certain activity occurs, so I figured I would express it as a percentage out of 7 (days) and model it using logistic regression. I would like to ...
0
votes
0answers
30 views

Why Does Perfect Separation Make Logistic Regression Prediction Impossible? [duplicate]

I had this issue a while back where perfectly separated data prevented a logistic regression model from being created. But why does this fail, from a mathematical perspective? Sorry if someone asked ...
1
vote
0answers
42 views

Inexplicable bad estimation in a Poisson regression (GLMM)

I need to use a Poisson regression to obtain the equivalent of a piecewise exponential estimation for the survival curve. So far so good. The problem occurs when I add a covariate to my time variable....
0
votes
0answers
23 views

Logistic regression: Understanding convergence towards coefficients from synthetic model

In preparation for working on real-world datasets, I am exploring classifiers on syntethically generated data. First I generate random variables $X_1 ... X_8$ that represent observables with physical ...
5
votes
1answer
53 views
0
votes
0answers
8 views

Error when averaging GLM models using `model.avg()` from package `MuMIn`

I already asked this question on the R forum but had no answers, so my guess is that it is better to ask here. I'm analysing some data using glmer(). Please bear ...
1
vote
0answers
50 views

R: lme4 vs. glmmTMB for binomial GLMM

I am fitting a GLMM to test if parasite prevalence in snails (positive snails divided by total snails) differs between different sites (site_type). Sites were ...
0
votes
1answer
37 views

Non-normal distribution and heterogenous variances

I have a data set in which I measured a continuous variable (positive, continuous data) in response to different treatments(15 different pathogens) and I am unsure how to statistically analyse the ...
0
votes
0answers
22 views

Adding covariate to GLM

My response variable is a count data (vse23). My explanatory variables are a combination of continuous (zastska, razkrit, zastveg) and categorical factors (mezo). I did a GLM model of variables that ...
1
vote
0answers
21 views

Group comparison for extreme value data: which method is suitable?

I have measured Gaussian curvature data of 3D objects from two different groups, A and B. I would like to find out whether the objects differ in curvature. The distribution of data values for each ...
3
votes
1answer
63 views

Are GLMs just glorified WLS regressions?

When performing weighted least squares $L = \frac{1}{2} \sum_i w_i r_i^2$, Aitken showed that one ought to weight each sample by the inverse of its variance $w_i=1/\sigma_i^2$. This leads to gradients ...
1
vote
1answer
42 views

Significant lags at ACF and PACF plots in GLM: what should I do?

A glm.nb model I built shows significant lags at lag 1 in both ACF and PACF plots. Please see the images below. There is no way to define random effects (or ...
1
vote
1answer
33 views

Literature / Books on Linear Models, Generalized Linear Models and Linear Mixed Models

As the title suggests, I'm looking for book recommendations on Linear Models, Generalized Linear Models and Linear Mixed Models. The book should give a good overview on the intuition behind ...
0
votes
0answers
20 views

How to compare turnover rates across three facilities over a period of 5 years?

I need to compare the turnover rates between 3 facilities (turnover calculated as number of voluntary & involuntary terminations divided by the average number of staff multiplied by 100). In ...
0
votes
0answers
15 views

Difference between “ * ” and “ + ” in R linear modeling [closed]

What is the difference between the code for a linear model with more than one explanatory variable with the symbol " * " and with " + "? here an example of what I mean: ...
3
votes
0answers
91 views

Nonnegative identity-link Poisson regression with ridge or fused ridge penalty

I would like to fit nonnegative identity-link Poisson regression models with a ridge or fused ridge penalty, i.e. with nonnegativity constraints on the fitted coefficients, Poisson error noise & a ...