Skip to main content

All Questions

Filter by
Sorted by
Tagged with
2 votes
1 answer
49 views

Dummy encoding for the multinomial response variable

I am reading about multinomial response models from the book Multivariate Statistical Modelling Based on Generalized Linear Models by Fahrmeir and Tutz. I am trying to understand the following ...
medium-dimensional's user avatar
3 votes
1 answer
362 views

Categorical variable disappears in Poisson GLM summary?

For the variable SelfEthnicity there is meant to be 4 levels. I have made it so there should not be a reference category, but the R output still only shows 3 Ethnicities. ...
user avatar
0 votes
0 answers
107 views

GLM specifying a subset of contrast matrix for factor variable

I'm fitting a binomial GLM with the following formula: glm(outcome ~ categorical:continuous:factor) I would like to see the interaction of categorical and ...
BioinformaticsB's user avatar
0 votes
1 answer
68 views

Are these effects missing from my glm output because of a possible dummy trap?

I have a few generalized linear mixed model questions. I have an experiment that asked "is there a differential response between asexuals and sexuals by population density?". I am ...
bribina's user avatar
  • 55
1 vote
1 answer
4k views

Interpreting GLM output with categorical data

I am having trouble identifying which reference level R is using for my response variable matnew. I know it sometimes chooses alphabetically, which in this case is "Fail", but I'm not sure ...
dolly's user avatar
  • 31
0 votes
0 answers
37 views

Can I just use one effect-coded variable instead of two dummy variables when I perform a regression, if there are 3 groups?

To make things simple, let say I ran a basic psychometric experiment and I want to test whether the response time (i.e. a continuous variable) can predict the performance score (i.e. a continuous ...
Christopher's user avatar
3 votes
1 answer
909 views

Interpreting the effects of dummy interactions

Warning This question is quite long, and maybe a lot of you will think it is too long. I however thought, and hope, that if this question gets a proper answer, it will actually be a really good post ...
Tom's user avatar
  • 528
0 votes
1 answer
29 views

Recalculate the standard error using a different base?

I want to run a GLM with a factor, say car type, as one of the independent variables. Suppose car type has the following levels: sedan, SUV, and truck. And suppose the base level is currently sedan. ...
platypus17's user avatar
1 vote
0 answers
70 views

Interpreting the covariate p-values in a multivariate generalized linear model?

If a covariate in a GLM is "significant" does that mean it is significantly different from the base case (the group not shown)? Say we have three groups, Control, Exp1, Exp2. We are ...
neurostats6's user avatar
1 vote
1 answer
585 views

Why are variables in GLM being split into multiple output variables

I have input for glm that looks like BMI $grp PRS age gene 24.2 1 3.0 77 0.0 33.8 1 4.0 89 0.0 30.3 1 7.0 58 0.0 I’m inputting this into ...
con's user avatar
  • 133
0 votes
1 answer
61 views

How to analyse count data that include 0 as a category?

I'm testing the yield of corn subject to two treatments: Temperature (Cold and Warm) and Light Color (Red, Blue, Natural.) The number of plants per plot that produced no cobs, one cob, two cobs and ...
je2018's user avatar
  • 51
0 votes
1 answer
54 views

How to handle potential ambiguity when one-hot encoding?

Let's say I have two categorical features: Movie, Director. I one-hot encode both the Movie and Director features for use in a linear regression model. The problem is that two or more movies may be ...
dan's user avatar
  • 1
1 vote
0 answers
2k views

When do I have to use orthogonal contrasts instead of non-orthogonal ones?

This is the same question as asked here, but of course I think with a different twist. A definition of orthogonal contrasts is given in another (great) answer to a popular question on Cross Validated ...
fabiob's user avatar
  • 712
1 vote
1 answer
486 views

How can I compute the standard error and confidence intervals for the base level on a variable?

I'm running a GLM with a tweedie, log-link function. That said, I have a categorical variable that transformed to dummy variables leaving off one of those variables when I modeled. Now that I'm ...
Jordan 's user avatar
  • 235
0 votes
0 answers
33 views

GLM Logistic regression in R: one category is significant, but others are not. Should I drop the variable? [duplicate]

so I am using GLM for logistic regression in R and I have some variables with many factors. I ran the model and has the result like this: My question is: 1. Is this variable significant? ...
user71812's user avatar
  • 123
1 vote
1 answer
1k 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 ...
JVal's user avatar
  • 11
0 votes
1 answer
1k views

h2o glm tweedie for categorical variables?

To build a tweedie glm for categorical variables, the document suggested that I can use data['variable_name'].asfactor(). However, in the model output, there is ...
Jie Huang's user avatar
0 votes
0 answers
36 views

Finding the fitted probability for an aliased constraint in a binomial model?

For a binomial model, with probit link function: model = glm(response~A+B+C, family = binomial("probit"), na.action = na.omit) where A and B are continuous, C is ...
thatsnotmyname71's user avatar
0 votes
0 answers
168 views

Model failed to converge in lme4::glmer() when the a factor is centered or releveled

I'm running a mixed-effects model using glmer() function. The modeling works well with R's default dummy coding. But if I center or relevel a factor of 2 levels, the model failed to converge. I am ...
chaoh's user avatar
  • 43
3 votes
1 answer
4k views

Results of Type-3 Wald Chi-Square Different for GLMM with Different Contrast Coding

I have just completed a multilevel, longitudinal logistic regression testing, at four different time points, whether participants in an experimental group are more likely to have committed any drug-...
llewmills's user avatar
  • 2,187
2 votes
1 answer
585 views

regression models and dummy variables

I have a output variable and 1 categorical predictor and 3 continuous predictors. ...
user3022875's user avatar
6 votes
2 answers
14k views

Using Non-numeric Features

I'm just starting out with machine learning. The example I was shown during a mini course I took was the predicting of the sale price of a house given features like: size of house number of floors ...
rodrigo-silveira's user avatar
6 votes
2 answers
11k views

Removing intercept from GLM for multiple factorial predictors only works for first factor in model

I am running a binomial logistic regression with a logit link function in R. My response is factorial [0/1] and I have two multilevel factorial predictors - let's call them $a$ and $b$ where $a$ has 4 ...
MiMi's user avatar
  • 73
6 votes
1 answer
5k views

Reference level in GLM regression

In GLM regression I have always been told to set the reference level of categorical/ordinal/dummy variables to the level with the most exposure (level with most data), because this somehow makes the ...
Erosennin's user avatar
  • 1,824
2 votes
1 answer
220 views

Model overall effect of predictor within categories

I'm trying to fit a generalized linear model in R, but am quite new to regression, and struggling to work out how to have predictors nested within categorical variables. An example of my data: <...
rw2's user avatar
  • 1,118
3 votes
1 answer
2k views

Non Numeric features in Logistic Regression

I understand that the fitted values for Logistic Regression can be expressed as: $$P(Y_i=1) = \left(1+\exp(-\hat{\theta}^TX_i)\right)^{-1}$$ where $X_i$ is the feature vector, which will work well ...
Saurabh Verma's user avatar
16 votes
2 answers
63k views

Understanding dummy (manual or automated) variable creation in GLM

If a factor variable (e.g. gender with levels M and F) is used in the glm formula, dummy variable(s) are created, and can be found in the glm model summary along with their associated coefficients (e....
Bryan's user avatar
  • 263