Stack Exchange Network

Stack Exchange network consists of 174 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

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 ...

0
votes
0answers
6 views

Setting the correct cutoff for binomial GLM's predicted probabilities

I'm using a binomial GLM to model what kind of student would pass or fail a certain class. When I use predict with type "response" on my model, I see a vector of probabilities. Per my understanding, ...
0
votes
0answers
15 views

Modeling based on certain constraint

I am dealing with a dataset that contains exactly one dependent variable $y$ and 5 independent variables $x_i:x_1,x_2,x_3, x_4,x_5$. My goal is to find the best combinations of $x_2,x_3, x_4,x_5$ ...
0
votes
0answers
7 views

Appropriate use of a GLM to look at what day differences between treatments become significant?

I am looking to analyze some organismal size data I have. Randomly assigned organisms were exposed to 6 different treatments over a period of 2 weeks with 6 sample events. I want to find the time ...
0
votes
0answers
11 views

Logistic regression appropriate with skewed outcomes?

I am currently examining a dataset pertaining to a specific behavior (chirping) in guinea pigs and the factors that influence whether a guinea pig will chirp or not. Previously, this behavior was ...
2
votes
1answer
35 views

What would be a Bayesian equivalent of this mixed-effects logistic regression model

I have been using "glmer" in R to model a binary outcome for approximately 500 persons, in two groups, each measured at three points in time. My questions of interest are a) whether the change over ...
0
votes
0answers
19 views

Crossed and multi-nested factors in GLM/Cox mixed models

In the fig. below there is a graphic summary of the experiment that I’m designing. I will have two factors (i) time that lobster egg clutches are exposed to the air (air-exposure), three levels of ...
0
votes
0answers
24 views

How to take the PCA components and perform a GLM with them alongside other data?

I have got a dataset that represents around 30 characteristics from a few hundred samples. Some of these characteristics could be condensed into 2 PCs as shown by a PCA. Now I would like to take these ...
0
votes
0answers
29 views

Variable Selection using automatic selection [on hold]

I have a data set with the following columns ...
1
vote
0answers
25 views

What is the difference between taking a transformation of a response variable to then apply linear regression and a GLM?

From what I've studied so far, GLM's are to be used when the error term of a response variable is not assumed to be normally distributed. However, I also read that sometimes a transformation of a ...
2
votes
1answer
17 views

count data and Poisson GLMs to predict monetary amounts

I have to predict money amounts, which are always greater than 0. The distribution is very tailed (i.e. there are many small values but also many large data). Just wondering would a count data model ...
0
votes
0answers
23 views

Determining which variables to use in regression model

So I'm trying to fit some binary outcome data to a logistic regression model. Besides the binary outcome I have several different metrics (numeric, integers, as well as factors) associated with each ...
4
votes
2answers
659 views

Is there any better alternative to Linear Probability Model?

I read here, here, here, and elsewhere that linear probability model (LPM) might be used to get risk differences when the outcome variable is binomial. LPM has some advantages such as ease of ...
0
votes
0answers
15 views

Tukey to check level differences after binomial logistic regression with glm()

I wonder whether the method proposed at this link is correct for my case: Comparing levels of factors after a GLM in R I want to use a binomial logistic regression to assess differences between the 3 ...
1
vote
0answers
17 views

How to compute effect sizes of single predictor in a logistical regression?

I have a logistic regression, with a binary response, a continuous predictor, and a categorical one. Is there any way to calculate the effect size of each of those predictors, similar to partial eta-...
13
votes
2answers
3k views

Do test scores really follow a normal distribution?

I've been trying to learn which distributions to use in GLMs, and I'm a little fuzzled on when to use the normal distribution. In one part of my textbook, it says that a normal distribution could be ...
1
vote
0answers
15 views

Why abline won't show line from glm with Gamma family? [migrated]

I have the following data, which I'm trying to model via GLM, using Gamma function. It works, except that abline won't show any line. What am I doing wrong? ...
1
vote
1answer
58 views

Post-hoc test for binomial GLM with some cases having probabilities of 1

I am studying the effect of plant survival on location and genotype. I fitted a binomial GLM and conducted a post-hoc test after significant interaction using the ...
0
votes
0answers
24 views

Is covariate a factor or numeric in R? [closed]

I wanted to do Covariance analysis using r. In order to do so how should i treat the covariate is it factor or numeric? Y ~ X + B + T , where y is the response variable (Biomass yield) X is covariate ...
2
votes
0answers
39 views

Zero-inflated highly skewed predictor variables

I've thoroughly searched this website and multiple others and can't seem to find an answer to my question. This is also my first post so I hope I've followed all the rules. I apologise for the length, ...
0
votes
1answer
36 views

BLUE estimators

I am studying BLUE estimators( Best linear unbiased estimates) in my stats course and I have understood until the derivation of B hat(regression coefficient estimate in y=Bx+error). Now my notes are ...
0
votes
1answer
13 views

Question on Scale-Location Graph

Hi guys, so I am working on an R assignment and I need to find whether or not one variable depends on the other. First, I want to check for assumptions before doing anything so I produced this graph ...
0
votes
1answer
12 views

adjusting for a binary confounder of a continuous predictor in a glm

I would like to predict the chance of receiving a blood transfusion based on hemoglobin level of a patient (hemoglobin continuous, blood transfusion categorical). I found that patients with low ...
2
votes
0answers
17 views

Log-likelihood calculation on separate test set

I'm looking for a "hack" in R that would allow me to calculate the log-likelihood of a GLM fit on a separate test set easily regardless of the distribution. For instance for a Gamma GLM, this is how ...
2
votes
1answer
53 views

Regression tree with nested data repeated in time (GLMERTREE, REEMTREE or REEMCTREE)

I work on the predation of seeds by insects (carabidae), and I am particularly interested in the effect of community composition on predation. I would like to know if the best predation rates are ...
0
votes
0answers
44 views

Using Gamma-log link GLZM for non-normal data?

My college supervisor for Psychology has advised me to use a GLZM (gamma family with a log link) to analyse my data set, on the basis that the response variable is 'all positive data, and is 'right-...
3
votes
0answers
66 views

IRLS for truncated normal GLM

I have data for which responses fall in $y \in [0,\infty)$ for which, it seems, the standard GLMs based on, say, gamma or inverse-Gaussian fail since they don't allow responses with values equal to 0. ...
0
votes
0answers
31 views

Error Term in Logistic Regression

I am trying to understand what the "error term" in logistic regression is. It's clear to me that the difference between the observed value and the predicted value with logistic regression will be 1 - ...
0
votes
0answers
10 views

Which error distribution should I use for Chao 1 estimator in GLM?

Chao 1 diversity index values are multipliers of 0.5 (at least in my data). Examples are 20.0, 15.5, 12.0, 9.5 and so on. It is either an integer or integer + 0.5. What error distribution should I use ...
3
votes
1answer
23 views

Unexpected estimate in Gamma GLM summary output

I have a question. How on earth is it possible to have a negative estimate for a form of a nominal variable (two forms: "HM" and "LM") when it should be positive? I'm modelling a positive continuous ...
0
votes
0answers
37 views

Can we unify generalized linear models and ordinary least squares by switching between two metric spaces

Lots of smart people out there. Maybe someone has seen this concept. In linear regression using ordinary least squares (OLS) we simply project the response Y onto the range of the design matrix X. ...
1
vote
0answers
13 views

Overdispersion problem in a quasi-binomial GLM (for proportional data)

Below is the summary of a GLM I built for a response variable which is proportional (derived from count data). My only predictor is a continuous one (environmental measurement). And my sample size is ...
2
votes
0answers
24 views

Simple GLM analysis on Springtail Community Dynamics: determining which variables affect Abundance

I'm looking at Springtail community analysis and want to see what, if any, affect Litter Type (LT), Site Type (ST), and Sampling Day (SD) have on springtail abundance. LT and ST both have 3 factors ...
0
votes
0answers
10 views

Truncating covariates if linear relationship breaks down for large values?

Suppose you fit a model $$y_i = \beta x_i + \epsilon_i$$ Where you strongly believe this linear relationship holds for the vast majority of observations. Suppose, however, that a small number of ...
2
votes
1answer
38 views

Is ACF plot enough to rule out auto-correlation in my model?

Do you think it's enough to check ACF plot to rule out possibility of auto-correlation in the data?
0
votes
0answers
16 views

Report, APA style, results of a binomial generalized linear model in R

This is the output in R of my binomial generalized linear model . Im looking for a guide or for guidance in order to report these results for an APA style publication.
0
votes
0answers
30 views

Logistic regression with negative weights in Matlab

I want to apply a logistic regression to a set of data where observations have been assigned weights depending on their "distance" from {0,1}. Most of the observations have weights within [0,1] range, ...
1
vote
1answer
9 views

What is the difference between a design matrix and a “factor loading” matrix?

I realise this is probability a naive question, but what exactly is the difference between your standard design matrix $X$ in $$y = X\beta + \epsilon$$ and a "factor loading" matrix $\Lambda$ $$y = ...
7
votes
2answers
90 views

huge difference between estimates of binomial regresssion when including random effect vs when not

I'm trying to estimate the average score for two groups of students. I use a binomial regression model. The total_ans is the total question they've have answered, ...
0
votes
0answers
43 views

Showing that $\sum_{i=1}^n y_i = \sum_{i=1}^n \hat{y_i}$

Exercise : Prove that for the Generalized Linear Model with a constant intercept $b_0$, the sum of the observed values equals the sum of the fitted values : $$\sum_{i=1}^n y_i = \sum_{i=1}^n \hat{...
2
votes
2answers
75 views

Showing that $\sum_{i=1}^n (y_i-\hat{y_i})(\hat{y_i} - \bar{y}) = 0$ for the generalized linear model [closed]

Exercise : Prove that for the generalized linear model, it is : $$\sum_{i=1}^n (y_i-\hat{y_i})(\hat{y_i} - \bar{y}) = 0$$ Question : How would one proceed with proving that for the generalized ...
2
votes
1answer
91 views

Modeling various skewed data

Below is a pair plot of the types of distributions (Time Series) I've been attempting to run models upon. Two of the features are strongly collinear (the distributions of last 2 on the diagonal of the ...
10
votes
2answers
372 views

Family of GLM represents the distribution of the response variable or residuals?

I have been discussing with several lab members about this one, and we have gone to several sources but still don't quite have the answer: When we say a GLM has a family of poisson let's say are we ...
0
votes
0answers
42 views

Is $\sqrt{y} = \beta_0+\beta_1x_1+\epsilon$ the same as $y=\beta_0+\beta_1(x_1)^2+\epsilon$?

Is $\sqrt{y} = \beta_0+\beta_1x_1+\epsilon$ the same as $y=\beta_0+\beta_1(x_1)^2+\epsilon$ ? If I am looking for the estimated coefficient for $(x_1)^2$ both equations, what should they be? Should I ...
5
votes
2answers
280 views

Regression when both the predictor and outcome variables are proportions

I am using $X$ The estimated pre-game win probability of a sporting team playing on its Home field (estimated according to a certain model) to predict $Y$ Actual proportion of points scored by ...
1
vote
0answers
10 views

Plotting fitted lines for two different groups from a glm model with an interaction [migrated]

I have the following model: mod <- glm(data=data, events ~ treatment * size, family = quasipoisson) With the following output: ...
0
votes
1answer
33 views

Degrees of freedom for a t ratio?

summary.glm() does not print degrees of freedom along side the t (or z) ratios. In many published studies, t ratios are reported with their p-values, but no DF. It ...
1
vote
0answers
38 views

Why does a summary() call on a GLM model give me T rather than F values?

I constructed a quasi-Poisson model ("mod") with two predictors and an interaction term using glm(). One of the predictors is ...
1
vote
1answer
19 views

Coefficients in Anova

When considering anova as a linear model where the variables of the model are categorical, I've heard that the coefficient given to a variable is the mean of the response in the group of that variable....
1
vote
0answers
14 views

difference between Wald and LR in Anova(car) and p-values

I am having difficulty understanding the p-values of a Anova(glm) in the car package in terms of Type II error. Are they testing ...
0
votes
0answers
15 views

Questions about analyzing proportions over time with Chi-square and building logistic regression/GLM models.

First-year med student who has been out of the stat game for some time. I'm looking at data for different residency sub-specialties (counts) and particularly interested in quantifying and comparing ...