Questions tagged [clustered-standard-errors]

Clustered standard errors represent the version of the general sandwich variance estimator that correct for (potential) grouping of the observations, e.g., repeated measurements clustered within an individual, or individuals clustered within a hierarchy level (geographical region, educational institution, etc.).

Filter by
Sorted by
Tagged with
0
votes
0answers
3 views

Random effects and cluster-robust standard errors

I have read that when one adopts Random Effects (RE) there is no need to include cluster-robust standard errors because of the structure and functioning of the RE model itself. Could anyone please ...
0
votes
1answer
32 views

Combining Error Terms into a General Error Term

Lets say I have 4 error terms: $$e_1,e_2,e_3,e_4$$ Each of these error terms come from different simulations of data using different classification methods. Let $\gamma$ be the number of empirical ...
0
votes
0answers
11 views

Cluster standard errors at the individual level in a panel

I am replicating findings of a paper that uses a panel of US counties. The baseline specification is a regression like this: $$Y_{zit} = T_{zit} + X_{zt} + a_{t} + b_{i} + u_{zit}$$ Where Y is an ...
1
vote
0answers
25 views

R package: Quantile regression with multiple group fixed effects and clustered standard error for more than 1 million data points [closed]

Could you please suggest R package for quantile regression that can include group fixed effects and clustered standard error for more than 1 million data points? I am afraid that ...
0
votes
0answers
25 views

Cluster issues for treatment effects analysis

I'm doing a Difference in Differences exercises on 32 regions within a country to test for the effect of a policy intervention. However, only 1 of those regions has been subject to the intervention; ...
1
vote
1answer
34 views

Intuition behind clustering standard errors

Intuitively, why does a lack of clustering standard errors lead to erroneously smaller standard errors? Looking at the calculations and seeing the difference between SEs that are clustered and not ...
1
vote
1answer
46 views

If fixed effects and robust standard errors both necessary, do they have to be at the same level, and why?

I am working on an empirical paper using repeated cross-sectional data, and a reviewer has asked that we cluster our standard errors at the same level as our geographic fixed effects. Given the ...
0
votes
1answer
27 views

Fixed-effects using demeaned data: Why different standard errors when using xt/reg?

My question is equivalent to this post: Fixed-effects using demeaned data: why different standard errors when using -plm-? which asks for getting the same SE in time demeaned regression as in fixed ...
0
votes
1answer
61 views

How to cluster standard errors (which unit to cluster over?)

I'm working on a cross-country study where I look at the impact of different regulatory variables on bank stability (so the dependent variable is at the country-bank-year level and the variable of ...
1
vote
0answers
20 views

Difference-in-difference: standard errors in nonparametric estimation and linear regression

It is well known that we can use a linear regression model to calculate the DiD estimate. I followed this website and created a simulation dataset. ...
2
votes
1answer
41 views

How are clustered standard errors and Newey-West errors related

As the question says, how are the two concepts related? As far as I understand, both approaches correct for heteroscedasticity and autocorrelation. Yet, they are different. Would applying one of the ...
1
vote
0answers
71 views

R plm cluster robust standard errors with multiple imputations

I am looking for a way to implement (country) clustered standard errors on a panel regression with individual fixed effects. That is, in plm() I want to define some ...
0
votes
1answer
69 views

Comparing clustering of standard errors between felm and feols functions

I'm using the lfe and fixest packages to run regressions with high-dimensional fixed effects. For these regressions, I would ...
0
votes
1answer
53 views

Variance Inflation Factors for a glm with clustered standard errors

I am using the glm.cluster function in R package miceadds and I would like to calculate the variance inflation factors (VIF), much as the vif function in R package car does. If I try to use car::vif I ...
0
votes
0answers
49 views

Replicating results with multiway clustering

I am trying to replicate table 2 of Nunn and Wantchekon (2011) (the paper data is available online). It involves a linear regression with fixed effects and adjusting for two-way clustering. The code ...
2
votes
1answer
182 views

How to block bootstrap in stata with set of dummy variables as controls

I want to estimate a Multiple multivariate regression of the type $$y_1=a_1+b_1*x+c_1*\text{countrydummies}+e_1 \\ y_2=a_2+b_2*x+c_2*\text{countrydummies}+e_2 \\ ... \\ y_N=a_N+b_N*x+c_N*\text{...
0
votes
0answers
12 views

performing a multilevel logistic regression: data naturally clustered but small clusters, singletons and limited number of 2nd level clusters: help?

I am looking to perform a binomial regression calculating the reselection chances of parliamentarians in the European Parliament based on their activity levels. DV= reselection: 0/1. My data is ...
0
votes
0answers
15 views

Adjusting standard errors for *both* heteroskedasticity and clusters in MATLAB?

My data is not exactly a panel, so I can't use the Panel Data Toolbox. It is over time (years) but not for the same industries. For example I have multiple rows with same industry in one year, and ...
0
votes
0answers
14 views

How to decide SE clustering unit?

I am working with survey panel data. I believe I should be clustering standard error, but I am confused as to which would be the right dimension. Is there a way to make an informed choice (by looking ...
1
vote
1answer
57 views

Strange looking funnel plot after computing cluster robust standard errors

I fitted the following hierarchical mixed-effects meta-analytic model using rma.mv() in the metafor R package. mod<-rma.mv(yi=yi, V=vi, mods=~ region + subtype, random = ~ 1 |study/id, data = es, ...
0
votes
1answer
55 views

difference in difference fixed effect vs clustered standard error

I am trying to run a difference-in-difference regression. I have one country in the treatment group and two countries in the control group. I believe there is a need to account for fixed effects to ...
1
vote
2answers
165 views

Does it make sense to use clustered standard errors outside of a regression framework?

I am unsure about how to proceed in the following context. Here is some toy data from R: ...
3
votes
1answer
148 views

How to cluster standard errors when fitting a model using maximum likelihood estimation in R?

I am estimating several parameters using the mle() function with the L-BFGS-B method in R to data from an experiment in which participants had to make multiple choices. My goal is to obtain population ...
0
votes
0answers
28 views

Cluster Standard errors with plm at higher level than group

my model suffers from autocorrelation, thus I wanted to cluster the SEs. I have firm level, industry level and country level observations in my model. A paper that I am following clustered the Ses at ...
0
votes
0answers
69 views

How to deal with overlapping observations in a regression?

I estimate model $Y_{i,(t+1)\rightarrow (t+6)} = \alpha + \beta \cdot X_{i,(t-11)\rightarrow t} + \epsilon_{i,(t+1)\rightarrow (t+6)},$ where $i$ is a firm, and $t$ is a month. Since the dependent ...
1
vote
1answer
44 views

One sample t-test with Groups?

I wish to find the mean dollar value in my data while properly accounting for different groups. Say for example I have a set of data as follows: ...
0
votes
0answers
16 views

Multilevel versus clusteredness in the sample

does anyone can explain to me the main differences between multilevel estimations and clustering correction? I think with HLM technique we can get estimation to the random parameters (the group level ...
2
votes
1answer
154 views

How can the clustered robust standard errors be smaller than the model based ones?

I ran a GEE model and I used it to check the difference between the empirical standard errors and the model-based one. For almost the variables, the empirical standard error was greater than the OLS ...
2
votes
1answer
76 views

Replicate Stata 'variance' and 'robust' in R for mixed effects methods [closed]

I am working with a small dataset of clustered data. The experiment is on mice, testing the efficacy of a substance for neurons cells within mice, and delivery of a fatty acid substance between mice. ...
0
votes
0answers
59 views

Three-way clustered robust standard errors in R

Suppose I have the following data: ...
0
votes
1answer
11 views

multilevel modeling or clustered SE when there is only one group

I am having a hard time deciding which modeling approach I should take. I have a survey data from a random sample from New York City. I want to explore the effect of NYC's number of crime incidence (...
2
votes
0answers
24 views

Standard error clustering: Does it depend on the variable of interest?

Suppose I am interested in whether a students age affects their performance, and I run the following regression: $performance(i) = \beta_1 age(i) + \beta_2 Female(i)+\beta_3 classsize(i)+\varepsilon(...
3
votes
1answer
185 views

Clustered standard errors and time dummies in panel data

Assume a simple linear regression model, I have $i$ firms and $t=17$ periods $$Y_{it}=\alpha + \beta_2 T_2 + \beta_3 T_3 + \cdots + \beta_{16} T_{16} + \gamma_i + \varepsilon_{it}$$ In this case, $t=...
2
votes
0answers
72 views

Variance-covariance matrix of individual fixed-effects seems to be biased by clustering

For some reasons, I am interested in the variance-covariance matrix of the individual fixed-effects when regressing wages on personal characteristics: $Y_{i,t} = X_{i,t} \times \beta + c_i + \epsilon_{...
1
vote
0answers
21 views

Is it a problem if cluster sizes vary wildly in a cluster-randomized experiment?

Consider a cluster-randomized experiment. There are 4,000 clusters and 2,000,000 observations. The dependent variable y is dichotomous, $Y \in \{0, 1\}$, and ...
2
votes
1answer
67 views

Clustering without test set and evaluation

I have to classify some data without any futher prediction (I just need the best clusters on the data). Do I still have to train-test-split my data or do a kfoldCV? And how do I evaluate my ...
1
vote
0answers
148 views

FE and clustered standard errors for a panel with firms, industries and years

I have an unbalanced panel of firms, years and industries. (1) At the moment I am running a panel regression with years and industries FE. My understanding is that I am counting for any omitted ...
2
votes
0answers
169 views

Adjusting for clustering and overdispersion in count models

My question is specific to the estimation of glm's and correcting for 'clustering' in a quasi-experiment (difference-in-differences). My outcome is counts of crimes....
0
votes
0answers
101 views

Replication of Stata commnad in R

I am not very good at working in R, usually I am working with stata. I just need to replicate one study in R. The command, which I need to replicate from Stata is : ...
0
votes
0answers
20 views

(How) can “de-meaning” help me solve this “clustering” issue?

I'm not particularly advanced when it comes to statistics and data analysis and have a problem I can't seem to solve. Basically, suppose you're doing school research and have three groups (to which ...
0
votes
1answer
221 views

Rearranging a Regression equation

I have what is probably a simple regression question but I thought I should ask since I don't have anywhere to verify it. I have an equation similar to as follows: $x_t = x_{t-1} + \alpha.Price_t$ ...
6
votes
2answers
1k views

Clustered standard errors - Why are SE smaller or bigger than OLS depending on cluster level?

I am analyzing some data using an OLS model. Data represent managers working for US cities. Within each city, we surveyed more than one manager (max 5). Multiple cities per state were surveyed. I'd ...
1
vote
0answers
99 views

Are Poisson Regressions with Serial Correlation Biased or Inconsistent? (No Fixed Effects)

Let's say I've got panel data where a count outcome $y$ and continuous independent variable $x$ observed each time period $t=(1,2,...T)$ for each individual $i$. I am interested in how $x_{it}$ ...
0
votes
1answer
476 views

Cluster-robust standard errors in panel data analysis

In a simple panel data analysis with data on 64 firms over 8 years, I use cluster-robust standard errors (at the firm level) to evaluate significance of coefficients. I observe important differences ...
0
votes
0answers
2k views

How should clustering be accounted for in logistic regression, when there are very few clusters?

I have survey data from 1000 patients. This is a convenience venue-based sample. In a specific city, at 9 hospitals that happen to have a psychosocial program, patients can opt into the program if ...
1
vote
0answers
140 views

hierarchical bootstrapping and calculation of variance (in a Random-Effects ROC Analysis) in R

I would like to calculate the variance of the AUC of readers (for each reader and averaged results) giving a score(1-5) to ...
1
vote
2answers
3k views

R | Robust standard errors in panel regression clustered at level != Group Fixed Effects

I want to run a regression on a panel data set in R, where robust standard errors are clustered at a level that is not equal to the level of fixed effects. That is, I have a firm-year panel and I want ...
3
votes
1answer
426 views

Why does ignoring dependencies between observations *inflate* my standard errors?

In the introductions to books and review papers about modeling dependent (a.k.a., within-subjects, repeated-measures, clustered, longitudinal, hierarchical) data, it is very common to say that ...
1
vote
1answer
326 views

Fixed effect and clustering with 3 dimensional data

I have a sample of banks. These vary across time, rating agency and across countries. UPDATE: I trying to capture the effect of a regulatory change (dummy variable, 0/1) on a banks credit rating. I ...
1
vote
0answers
168 views

Logistic Regression: Using weights?

I am running a logistic regression model with the following data and variables: Independent variables (characteristics of a person coded as dummy) Test score (continuous variable between 0 and 1) ...