Skip to main content

All Questions

Filter by
Sorted by
Tagged with
1 vote
2 answers
30 views

Should I conduct a multilevel for this or another analysis? Need help

I have three sources of data (teachers, parents and students) assessing students, in three waves. I want to assess all and see the differences between moments but then I also want to use variables for ...
Margarida Santos's user avatar
1 vote
0 answers
9 views

Fauna activity responses to fire with camera traps - issues with lacking spatial independence and how to analyse

I am trying to work out the best approach for data analysis for my PhD and have gotten a bit stuck. I am working in the field of ecology, trying to understand responses of fauna before and after a ...
Gabrielle Brennan's user avatar
1 vote
0 answers
11 views

How to model frequency data with mixed effects?

I have some frequency data that I am not sure how to model I have two independent experiments (replicate: A, B), where I treat neurons (10 per treatment) with the same drug but for different time ...
Sebastian Rivas's user avatar
3 votes
2 answers
105 views

R: How to fit a linear mixed model with a custom covariance structure for two random intercepts

Suppose I have a dataset with repeated measurements on q clusters. I want to fit an LMM with two random intercepts, on the same cluster, with a non-diagonal covariance structure on the random effects (...
Giora Simchoni's user avatar
-1 votes
0 answers
8 views

what happens when a network has low closeness centrality - what happens to nodes on the periphery [closed]

I have thirty-nine nodes with closeness centrality scores but I do not know what to say about the nodes on the periphery who do not have scores.
user451331's user avatar
3 votes
1 answer
46 views

Calculate marginal effects for random effects model with two crossed random effects

I am trying to get effects marginal of two crossed random effects (using STAN or brms). I understand how to do it for a single random effect following McElreath's book and Kurtz's brms version of the ...
Christopher Rounds's user avatar
4 votes
2 answers
41 views

Accounting for non-independence and autocorrelation in HGAM

I am currently trying to fit a HGAM to model differences in daily activity patterns of fish in two treatments. Data were collected with high-resolution telemetry, and I currently have estimates of ...
Jack B's user avatar
  • 105
0 votes
0 answers
22 views

Derive gamma-parameters from preset R^2 in mixed models

For a simulation study in R, I want to select the effect sizes according to a preset $R^2$. Consider this two level random intercept mixed model, with one L1 predictor $X_{ij}$ and one L2 predictor $...
Linus's user avatar
  • 153
0 votes
0 answers
9 views

Extracting individual level posterior class memebership probabilities in multilevel LCA

I am conducting a multilevel laten class analysis using the R package multilevLCA. I have fitted the model using multiple steps (i.e. determining optimal number of classes as well as clusters). I now ...
Simon's user avatar
  • 1
1 vote
1 answer
37 views

Correct binomial GLMM for temporal trends in species occurrences

I have a dataset with 80 species which were sampled in about 120 water bodies at two time periods (historical / recent). Only presence/absence of the species in each water body is considered. The data ...
Friede's user avatar
  • 11
6 votes
1 answer
125 views

Is there a way to forecast by subgroup without forecasting each subgroup separately?

I am trying to find an appropriate model to forecast the number of applications received at the end of a recruitment cycle based on previous recruitment cycles and the number of applications received ...
Richard Manser's user avatar
0 votes
0 answers
42 views

LMM: effect of day may differ between subjects - fixed or random effect?

We tested 12 animals in a test with three phases (a/b/c) in three conditions (C1/C2/C3) on nine days, i.e. every animal experienced each condition three times. On each day, four animals were tested in ...
bos's user avatar
  • 13
1 vote
0 answers
49 views

Opposite results using Bayesian (STAN) vs Multilevel model (nlme). How is this possible?

My datasets contains the median wages and the cumulative installed wind-capacity for 4000 counties over a period of 20 years. The wages tend to rise over the period and the capacity tends to highly ...
user442239's user avatar
0 votes
0 answers
18 views

How to Forecast Sales for Sub-Locations Without Historical Proportion Data?

I have a time series dataset of total sales for a product in a store over time. This product is available in two different locations within the store: one stand near the checkout and another stand in ...
Raheshi Knuwga's user avatar
4 votes
0 answers
73 views

Major discordance between uncertainties estimated by `predictInterval()` and `bootMer()` for binomial GLMM with cloglog link

We have been using predictInterval() from the merTools package to bootstrap uncertainty for binomial GLMM models (complementary ...
Karthik Thrikkadeeri's user avatar
0 votes
3 answers
43 views

Problem finding a distribution for my data (glmm)

I want to do a correlation analysis of two variables ranging from zero to one (including those values), and including other possible environmental explanatory variables. I opted for a mixed model, ...
LidiaFernandez's user avatar
0 votes
0 answers
32 views

GLMM with log-Gaussian, log-Gamma

I need someone smarter than I am to look at this problem, and I'd appreciate it if you'd take the time. So, I am trying to predict reaction times here in a glmm using a battery of IVs. You can see the ...
Waaaayne's user avatar
0 votes
0 answers
24 views

Multilevel Model in R

I have data from a study in which 19 participants (9 males, 10 females) have each completed 4 jumping conditions (BW, 20, 25, 30) whilst I have measured joint level data for the hip, knee and ankle. I ...
teli95's user avatar
  • 1
0 votes
1 answer
42 views

CWC(M) in multilevel modeling

I am new to multilevel modeling and recently learned about CWC(M) by Zhang et al. (2009, https://journals.sagepub.com/doi/abs/10.1177/1094428108327450). I am running a multitlevel moderated mediation ...
AUPW's user avatar
  • 1
0 votes
0 answers
22 views

Can you add interactive effects between Principal Components (PCs) and other predictors in linear models?

I am building a glmm where I have 3 PCs (principal components) as predictors in the model. These PCs are based on soil variables (pH, CEC, nutrients) so I have reason to believe they may interact with ...
Emma Neigel's user avatar
0 votes
0 answers
12 views

mice multilevel imputation: does specifying cluster variable ("-2" in predictor Matrix) without multilevel methods lead to cluster robust imputation?

In short: Are mice's imputations cluster robust when I only specify the cluster variable with "-2" in the predictor matrix but do not use multilevel models during imputation? For clustered ...
JannisB's user avatar
4 votes
1 answer
45 views

How to Simulate a Multilevel Predictor Variable with Both L1 and L2 Variance Components?

I'm working on simulating multilevel data where I have a predictor variable measured at Level 1 (L1), which has both L1 and L2 variance components. For example, I want to simulate a socio-economic ...
Linus's user avatar
  • 153
2 votes
1 answer
35 views

Reporting Hierarchical Regression Results in Abstract

I did a hierarchical regression test in a social science study looking at how two variables (A and B) and their interaction term can predict variable C. My mentor told me to write in the abstract that ...
kangaroo123's user avatar
1 vote
0 answers
16 views

bear data set: glm or glmm?

I have a dataset where I am trying to determine the speed of bears depending on their sex, the year and the season. Some of my bears have multiple seasons of data: out of 79 bears, 19 had data for two ...
Cam's user avatar
  • 161
0 votes
1 answer
33 views

Mediation models require a sigma matrix that is symmetric

I'm trying to fit the following reproducible mediation model called final. But I get an error saying: sigma must be a symmetric matrix Could you please advise how ...
Simon Harmel's user avatar
2 votes
0 answers
16 views

Which estimator to choose for meta-analysis^ REML or CR2 with Wild Bootstrap?

I am following the following book: https://bookdown.org/MathiasHarrer/Doing_Meta_Analysis_in_R/multilevel-ma.html I can't choose which estimator to choose: REML or CR2 with Wild Bootstrap. Or maybe ...
YuliaM's user avatar
  • 21
3 votes
1 answer
61 views

How can we simulate correlated random variables that vary at different levels in a multilevel/mixed effects setting?

I am very familiar with generating correlated random variables from a multivariate normal distribution. This question is about doing that in a multilevel setting, where variables only vary at ...
Robert Long's user avatar
  • 65.8k
0 votes
1 answer
21 views

Modelling a continuous covariate measured at every observation time point

I have a within-subjects design where I measure the dependent variable at 4 time points, repeated measures, in a number of participants (say 30). To use an analogy (without getting into the specifics ...
sportsscientistse's user avatar
2 votes
1 answer
78 views

General formula for mixed models

I'm trying to wrap my head around the general formula of mixed models and how it relates to the system of equations I'm used to. The general formula read like this: $$\mathbf{Y_{j}}=\mathbf{X_{j} \...
Linus's user avatar
  • 153
7 votes
1 answer
134 views

Using proportions as a measure of nest success in a glmm

I want to run a GLMM to see if a conservation intervention had an effect on the nesting success of a shore-breeding bird. I'm comparing this against a control where no intervention was used. I used ...
kmew's user avatar
  • 71
4 votes
1 answer
39 views

Outcome in mixed models - lower level or upper level?

I am learning about mixed models and I have a question regarding the outcomes that can be considered. If I have hierarchical data, do the outcomes that I can consider need to belong to the lower level?...
niqp's user avatar
  • 43
8 votes
1 answer
471 views

Power analysis for three-level multilevel models in R

For a study in a social science setting - where huge number of participants are not easily available - I'm trying to do a power analysis for a three-level multilevel design. There are few packages ...
Linus's user avatar
  • 153
4 votes
2 answers
165 views

Can we calculate population mean response from GLMM by averaging over random effects?

I am trying to understand how we can estimate the effect of a covariate on population mean response when we have fitted a generalised linear mixed model with non-linear link function to the data. I ...
medium-dimensional's user avatar
0 votes
0 answers
25 views

Using GLMs or GLMMs for diversity metrics

I would appreciate some help in a question regarding statistical analysis. I'm looking at species count data where sampling was carried out over multiple years in repeated sites. So each year was ...
user390865's user avatar
1 vote
0 answers
15 views

How to Set Up a Polynomial Multilevel Model

I have a modeling situation that I am not 100% sure how to approach. I have two independent variables, information and time, with time being a repeated measure. The dependent measure is difference. ...
Gabrielle's user avatar
3 votes
1 answer
73 views

DHARMa residual pattern

I'm trying to model a behavior using glmmTMB with a beta distribution (as suggested in another post). My model consists of several fixed factors and two random effects (species and individual). I have ...
Dmitry's user avatar
  • 33
1 vote
1 answer
56 views

Multi-level modelling?

In an instructional study, I have pretest and post-test measures of writing quality--no control condition. There are 110 students nested in 10 classes. I have pretest measures of spelling skill and ...
pkleinuwoca's user avatar
3 votes
2 answers
88 views

Using Zero inflated GlMM when you have too many zeros

I am trying to understand the influence of several predictors (n=8) on the presence or absence of a species using generalized linear mixed models. Unfortunately, I do not have great data. I have 13000 ...
Tammy's user avatar
  • 41
1 vote
1 answer
46 views

Do I need to run a Poisson GLMM?

I have been asked to perform a GLMM to study which conditions most influence certain behaviors in captive animals. The dependent variable is the time spent on each behavior during a 10-minute ...
Dmitry's user avatar
  • 11
1 vote
0 answers
62 views

Prediction Intervals With Hierarchical Regression Model

I'm reading this data analysis book by Gelman and Hill and am trying to understand predictions with hierarchical models. On page 273 they are demonstrating making new predictions for an already ...
RSHAP's user avatar
  • 133
0 votes
0 answers
8 views

Random effect nested in two crossed fixed factors

I have presence/absence diagnoses from 20 doctors for each of 50 samples from 5 patients (10 samples from each patient which differ according to two factors). The doctors are one of three specialist ...
Anna Jackson's user avatar
2 votes
0 answers
46 views

How do I determine if my ecological GLMM is accurately constructed?

I am an early career ecologist/biologist and I have been working on a Generalized Linear Mixed Model in R to determine influential variables to wildlife behavior. I have been learning as I go and I ...
Alyssa's user avatar
  • 21
0 votes
0 answers
25 views

Improving glmm accuracy - what can I do here?

I'm working on a model in R but my validation suggests it's breaking some assumptions - non-normal residuals and heteroscedasticity. My dependent variable is highly skewed, and originally bounded (but ...
drsp's user avatar
  • 1
1 vote
0 answers
56 views

Error in lmerTest: The random-effects parameters and the residual variance (or scale parameter) are probably unidentifiable

I know that there have been similar questions before, but I dont still get it. I would like to estimate a multilevel model with repeated measures in R using the package “lmerTest”. The model ...
Ineluki's user avatar
  • 11
2 votes
0 answers
19 views

Hierarchical models where the hierarchy structure depends on a latent variable

I am having trouble formulating a hierarchical model for the purpose of Bayesian inference in the case where the actual hierarchical structure depends on a latent variable. I am wondering if this is ...
gabe's user avatar
  • 131
2 votes
0 answers
39 views

Can I Perform a Micro Synthetic Control Analysis with Different Aggregation Levels for Treatment and Control Groups?

I am conducting an analysis using the microsynth package in R to evaluate the impact of increased police presence on various outcome measures obtained from an official survey. My treatment areas ...
DeMelkbroer's user avatar
0 votes
0 answers
11 views

Fitting nonlinear Bayesian regression with a summation term in brms

I'm trying to fit parameters for a Holling type II curve for multiple prey items. This takes the form: $$ \frac{dP_i}{dt} = \frac{a_iP_i}{1 +\sum_j{a_jh_jP_j}} $$ where $P_i$ is density of prey ...
Jacob Weverka's user avatar
1 vote
1 answer
26 views

Setting predictor variables with 3-levels in multilevel mode

I am working with a random intercept multilevel modeling. I want to predict general health based on survey data. The survey uses nested data set on three levels: individual, county, and state. I am ...
YouLocalRUser's user avatar
3 votes
1 answer
48 views

Mixed Model: Translation from mathematical notation to R's lmer() - package: lmerTest

The following data should be generated and fitted to a mixed model (for further simulation studies): $y$: outcome of clinical study (effect of medication) indiv individuals = 20 repl replicate ...
m09s19's user avatar
  • 95
1 vote
2 answers
35 views

About adding random effects in Multilevel (HLM) analysis

I am doing regression analysis in HLM. I am wondering whether random effects should be added in this process. Let me ask a question using a famous example. LV1 is a student and LV2 is a school. LV1 ...
Nobody Nobody's user avatar

1
2 3 4 5
60