All Questions
1,273 questions with no upvoted or accepted answers
0
votes
1
answer
132
views
Can I GROUPMEAN center one variable and not the second one involved in an interaction / Multilevel Model with L1 Moderation
I'm fitting a multilevel model with an L1 moderation on Mplus.
I am trying to demonstrate that the effect of X (independent variable / mean of scale items) on Y holds only when people do not make a ...
0
votes
1
answer
254
views
Can I use Gls() or glmer() to predict binary outcomes with restricted cubic splines predictors?
I'm new to rms, as I read the rms book and notes, I saw that the Gls() function could be used to make a longitudinal growth ...
0
votes
0
answers
572
views
How can I address the autocorrelation in my glmm?
I am looking at effect of diet on breeding success of birds. For 8 years, I have breeding success (number of chicks fledged / number of eggs laid), as well as Frequency of Occurrence (FO) of Fish in ...
0
votes
0
answers
140
views
Struggle to choose a model (glm, glm with qualitative variable, glmm)
I'm currently trying to fit a model on some data, but I am quite struggling.
Data
There are 20000 entries in the dataset. One entry is a random pick of bacteria (among a set of ~200 bacteria).
The ...
0
votes
0
answers
37
views
Can I evaluate additive interaction for GLMM
I am currently running a GLMM (log-link function) examining the effect of two treatments on the instances of an arthropod. I seek to determine if there is additive interaction between the two ...
0
votes
0
answers
43
views
Multilevel logistic regression: is it possible to apply
We conducted a study and the results submitted to a journal and one of the reviewers suggested me to conduct a hierarchical logistic regression. Basically I know how to conduct multilevel regression ...
0
votes
0
answers
252
views
How does lme4 calculate residual variance for an LMM?
How does the lmer() function calculate residual variance for an LMM? If I code a model and then try to manually calculate residuals, the variance of the manually ...
0
votes
0
answers
241
views
How to evaluate overfitting in GLMMs usnig R
I am using glmmTMB in r to model count data. I use poison and negative binomial error distributions. If I add one more predictor to my models I end up having convergence problems. I would like to ...
0
votes
0
answers
128
views
Negative % variance explained for Cross-validated Hierarchical Generalized Additive Model
So I have a dataset I've split into training & test with an 80/20 ratio. It's a hieararchically structured dataset, individual human participants each with many observations, so when splitting I ...
0
votes
0
answers
214
views
Handling 0s in a generalized linear model---climate data
I am using a generalized linear mixed model for analyzing climate data and incidence of a disease variable. The data follows a gamma distribution. But I am getting the following error when I am ...
0
votes
0
answers
266
views
When to use robust one-way repeated measure design ANOVA?
I have a set of 9 different factor levels from my independent variable to be compared against each other. Here are the results of the different assumption tests in R. I'm just going through my ...
0
votes
0
answers
192
views
Can we use macro variable (e.g.gdp_growth) in a panel data?
I am examining one country over a period of 10 years. I am interested to see whether GDP_growth had a heterogeneous effect on wages across people with different educational background. The code below ...
0
votes
0
answers
26
views
Can I be sure about the parameter's SIGN if the convergence is problematic?
I fitted a large multilevel SEM model, used a 1 million iterations and 8 chains, but for some parameters the estimates still diverge across chains, and the corresponding autocorrelations are above .6 ...
0
votes
0
answers
70
views
specifying random effects in mixed effect model when each observation can have a subset of levels from a category (as opposed to exactly 1)
The problem is the following: I have data from several basketball games. Each row of data is 5 players and the number of points their team scored during the game. My response variable would be the ...
0
votes
0
answers
136
views
Options when model complexity and separation causes non-convergence in logistic regression
I have created an example data set here
My data represent the presence/absence of a particular animal species (data$outcome) and measurements of trees. I would like ...
0
votes
0
answers
30
views
Appropriate regression model for a learning experiment on alpine skiing
We are running a learning experiment with a between-subjects design on alpine skiing: one group training according to an interleaved schedule whereas the other group train according to a blocked ...
0
votes
0
answers
158
views
How to model negative zero-inflated continuous data?
I am currently trying to apply a model (family = gaussian) to an indicator of sentiment score, values range from -4 to +2, is zero-inflated and is continuous.
I want to look whether there is a ...
0
votes
0
answers
317
views
Mixed Effects Poisson Regression with Nesting?
I have collected data for a study that had the following design:
Subjects walked through a food pantry five different days during one of two conditions: signs-down (no signs displayed, 2 days) and ...
0
votes
0
answers
32
views
What is the best approach to predict/ forecast the sales of 100s of parts?
I have been working on a sales database, aggregated and organized month wise, which has the sales trend of 600+ parts, of which 150 are major contributors. The parts can be aggregated into a part ...
0
votes
0
answers
41
views
Positive z score but lower mean value
I ran a GLMM to check the increase or decrease of the dependent variable on two fixed effects (condition "Presence and condition "Absence") as:
...
0
votes
1
answer
174
views
Why do results differ with and without offset in Poisson regression?
I have a dataset with counts of preterm births for five years by county. I am running analyses to see whether contaminant water concentration levels for each county for each year predict preterm ...
0
votes
0
answers
425
views
Comparing the means of latent variables in a CFA model measured at two different times in R
I have a CFA model with 7 latent variables and about 4 items per construct, I'm using R with lavaan for the CFA, $N\approx 3500$.
My model looks like this:
...
0
votes
0
answers
47
views
Multilevel model for change- time-varying variables at different waves to outcome
I am using UKHLS youth survey where an outcome for wellbeing occurs at waves 2,4,6 and 8.
I have predictors such as computer screen usage and many others I would like to use occurring at waves 1,3,5,7....
0
votes
0
answers
38
views
Best way to deal with count data going from 1 to 3?
I want to perform a model with multiple independent variables and 2 random effects to see their effects on clutch size.
This is a plot of my response variable.
My model
...
0
votes
0
answers
67
views
What are the recommend approaches for adjusting forecasts made at a detailed level, to match a forecast made at an aggregate (total) level?
Intuitively, I have a greater confidence in a forecast performed on data at an aggregate (e.g. total company) level than the sum of forecasts at made a detailed level (e.g. product).
However, when ...
0
votes
1
answer
21
views
confidence interval of estimates with sumcoding
I am using sumcoding for my treatments in my design matrix $X$, as such I leave one treatment out and estimate these as follows ...
0
votes
0
answers
74
views
Mean, median, or mode? Shifts in significance of interaction effects in a model based on computation of response variable
I have a multilevel model in which my response variable consists of a variable that is computed as the mean value of a set of observations (scored from 1 to 7). However, when I compute my response ...
0
votes
0
answers
25
views
Ok to repeat same measurement in different column and different row of design matrix for multilevel model?
I have a process that unfolds in time for each participant like this:
measurement1 -> event1 -> measurement2 -> event2 -> measurement3
Each of these ...
0
votes
0
answers
34
views
Hierarchical model with a different set of covariates by group
I'd appreciate any good reference material on specifying a hierarchical model with a different set of covariates by group. Textbooks usually reference varying intercepts and slopes, but in my real ...
0
votes
0
answers
36
views
Diary study: Should I model time with very unbalanced time-points? (Multilevel analysis)
I have a data set from a diary study in which daily stress during the current pandemic was assessed for 30 days. However, participants began their diary period at different time points, leading to an ...
0
votes
1
answer
32
views
How to interpret interaction in the absence of main effect? Multilevel Modeling
What is the substantive interpretation of an interaction in the absence of a main effect? Statistically I understand that the interaction modifies the main effect, but how to interpret this from a ...
0
votes
0
answers
79
views
Calculating group-level mean with varying group sizes for micro-macro data structure
My study is designed in such a way that I have individuals with varying numbers of observations of the predictors, but only one observation of the outcome. Like a multilevel model, but with the ...
0
votes
0
answers
332
views
Best normalization method for judge scores?
I am working on a dataset in which 10 judges each rate 5 teams (50 teams total). Since each judge differ greatly in their evaluation criteria (i.e., some of them overrate and others underrate), I am ...
0
votes
0
answers
45
views
Converting LMM to GLMM
I've fit my model using lme (in nlme, R). However, this is not normally distributed. Taking the log of the outcome variable ...
0
votes
0
answers
400
views
Forecasting sales for thousands of stores individually with multiple features associated
I have data of 2000 stores with associated 145 features (example: ambience, holidays, no. of brands) and their monthly sales for 2 years. It means that for every store I have sales data and other ...
0
votes
0
answers
48
views
Standardize species richness by elevation
I am studying the effect of forest structure on recruitment. One of the variables is species richness defined as the number of species.
The aim is to quantify the effect of species richness on ...
0
votes
0
answers
236
views
Multivariate hierarchical linear model via nlme
I'm running a multivarialte repeated measures hierarchical linear model in r's nlme package. I have three dependent variables D1, D2, and D3.
My variable structure is such that a time point is nested ...
0
votes
0
answers
153
views
Linear model for nested within subject design
I want to find a suitable linear model for my analysis. I have a nested experiment design. There are 2 conditions, 40 subjects, and 20 measurements within a subject. The condition is a within subject ...
0
votes
0
answers
49
views
Questions about Random Effects in GLMMs
Someone reccomended me to use GLMM instead of GLM for the data I used for the manuscript.
My data corresponds to transects in which I have counts of individuals of a species in several points along ...
0
votes
0
answers
35
views
Can I discard parameters with a R-hat > 1.1 and consider the rest of parameters with a good R-hat value?
I have a binomial glmm model containing many regressors. When summarizing the estimates, some parameters show R-hat > 1.1, indicating chains have not mixed and estimates should not be trusted as ...
0
votes
0
answers
3k
views
P values from lmer with lmerTest - why REML= TRUE?
I would like to obtain p-values from my model fit with lmer()from the lme4 package.
It looks something like this:
...
0
votes
0
answers
44
views
How can I fix the output of a GLM that only gave me "NA" in R Studio?
I'm trying to see the isolated and combined effects of precipitation and three different human disturbances indexes are having an effect on the growth of a cactus. I have a gradient of eight different ...
0
votes
0
answers
797
views
Omit a random effect when its variance is >0 but <1?
On two threads, here and here, it suggests that random effects in GLMMs can be omitted if their variance approximates 0. This raises the question, below which level of variance can you reasonably omit ...
0
votes
0
answers
275
views
Aggregate time-series forecast from individual probabilities
I'm conceptualizing a methodology for a time series forecast but I lack the terminology and even the notation to learn more or even adequately describe it.
Suppose I aim to forecast the aggregate ...
0
votes
1
answer
27
views
What is the best way to examine the interaction between student gender at level 1 and instructor gender at level 2 in a multilevel model?
I am building a multilevel model with students at level 1 and instructors at level 2 and I have variables at each level to indicate the gender of the students and their instructors (see coding below). ...
0
votes
0
answers
93
views
What is the best way of reducing the number of independent variables of a GLMM?
I am trying to model the abundance of beach litter across different beaches by using (currently) 13 independent variables. I have a very big dataset and therefore think that it is acceptable to use ...
0
votes
0
answers
154
views
Which test to use when comparing two variables of which one has multiple levels?
Here's some example data:
...
0
votes
0
answers
72
views
Dealing with highly skewed residuals in GLMM
I am trying to see if there is a relation between the proportion of target vs non target species in some communities and their phylogenetic structure. I cannot show you the real data but it looks ...
0
votes
1
answer
98
views
Regression analysis when the independent variables are part of each other
I would like to correlate the equipment total number of working hours per day to the total dispatched/shipped qty per day. However, I believe that two products will have more effect than others (more ...
0
votes
0
answers
135
views
How to estimate parameters of a hierarchical model?
I have the following hierarchical model,
where $t$ stands for time and $y_t, x_{1t}, x_{2t}, \dots, z_{1t}, z_{2t}, \dots$ are known. I want to estimate the parameters of the model using a ...