# NOT RUN {
library(fwildclusterboot)
library(fixest)
data(voters)
feols_fit <-feols(proposition_vote ~ treatment + ideology1 + log_income,
fixef = "Q1_immigration",
data = voters)
boot1 <- boottest(feols_fit,
B = 9999,
param = "treatment",
clustid = "group_id1")
boot2 <- boottest(feols_fit,
B = 9999,
param = "treatment",
clustid = c("group_id1", "group_id2"))
boot3 <- boottest(feols_fit,
B = 9999,
param = "treatment",
clustid = c("group_id1", "group_id2"),
fe = "Q1_immigration")
boot4 <- boottest(feols_fit,
B = 10000,
param = "treatment",
clustid = c("group_id1", "group_id2"),
fe = "Q1_immigration",
sign_level = 0.2,
seed = 8,
beta0 = 2)
summary(boot1)
plot(boot1)
# }
Run the code above in your browser using DataLab