297 questions
1 vote
0 answers
74 views
Can statsmodels be used to obtain clustered standard errors in a fixed effects regression model? (Python)
I have a cross-sectional dataset and am doing some simple econometric exercises with it using the statsmodels package in Python. At a certain point I tried to run a fixed effects regression model ...
1 vote
1 answer
160 views
fixest - sandwich compatibility in R to estimate bootstrap standard errors in feols
The fixest package documentation says that it is compatible with sandwich "Compatibility with sandwich package The VCOVs from sandwich can be used with feols, feglm and fepois estimations" (...
0 votes
0 answers
54 views
How can I get the standard error of the standard deviation of the random intercept in a cumulative linear mixed model using "ordinal" package in R?
# A tibble: 7,500 × 4 cluster cluster_size x ordinal_y <int> <int> <dbl> <fct> 1 1 1 2.57 4 2 1 2 3.59 4 ...
1 vote
0 answers
157 views
Difference in Standard Errors and p-Values in Two-Way Fixed Effects Logit Model with Interaction Terms using fixest Package in R
I'm working with a two-way fixed effects (TWFE) logit model in R using the fixest package. My model includes interaction terms between some fixed effects and a categorical variable called group. To ...
1 vote
0 answers
40 views
How to generate a bootstrap standard error, t statistics and p value for a user written dynamic panel quantile regression
rm(list=ls()) library(quantreg) library(SparseM) library(stats) rq.fit.panel <- function(X,y,s,w=c(1),taus=0.30,lambda = 0){ # prototype function for panel data fitting of QR models # the ...
2 votes
1 answer
325 views
(Zero Inflated) Negative Binomial Regression with Conley Standard Errors and Weights
My goal is to run a negative binomial regression with conley standard errors and weights. Further below I separately ask about a zero-inflated negative binomial model. To my knowledge, a negative ...
0 votes
1 answer
500 views
Clustered/Robust standard errors in R
I am estimating an OLS regression without fixed effects and an OLS regression with fixed effects in R Studio. I have read, that it is common to use robust standard errors, when estimating a simple OLS ...
0 votes
1 answer
657 views
HAC standard errors in R using plm package?
I want to estimate a fixed effects model (with both country- and year fixed effects) and ADDITIONALLY apply HAC standard errors. Although I didn't get any error message after running the following ...
1 vote
1 answer
184 views
How to reverse engineer a dataset?
My teacher gave me the result of a regression and the exercise is to reverse engineer the data set that lead to that regression. Then we need to do a regression on it and find the exact same results. ...
1 vote
1 answer
721 views
Is using the cluster(clustvar) option the same as using vce(cluster clustvar)?
I would like to understand what the cluster option in Stata is doing, preferably directly from official Stata documentation. For example: reg outcome predictor, cluster(clustvar) The documentation I ...
0 votes
0 answers
518 views
Replacing Standard Errors in a GLM Model in R [Follow-up]
My post is a follow-up question to this one: Replacing Standard Errors in a Reg Model in R I am in search of a way to directly replace the standard errors in a regression model with my own standard ...
0 votes
1 answer
185 views
Regression Coefficients with Interactions and Clustering
I am running a linear regression model that has interaction terms and double clustering, and am having a hard time with getting the combined regression coefficients and 95% confidence intervals in R. ...
2 votes
1 answer
381 views
Is there a way to calculate standard errors for predictions using the geeglm function from geepack?
I want to visualize the results of my model. I do not want to obtain predictions for new individuals. When I try to use the argument se.fit = TRUE in the predict function with a GEE fitted with ...
1 vote
1 answer
48 views
Testing how well my test data fits to a sinusoidal template in R
In my dataset, I have split my data into testing and training. I have used the training data to fit a sinusoidal curve. freq = seq(from=21, to=80, by=0.5) amp = c(-45.22247,-44.87434,-44.30659, -44....
0 votes
1 answer
62 views
How to add all data to a facet_wrap ggplot standard error plot (where facet wrap is already being used to denote a factor)
I'm trying to plot a multipane figure which displays standard error plots of various biodiversity metrics. I have data from five rivers but I want to display the five rivers independently (currently ...