When I run this code I get Error in scale_override_call(call) : could not find function "scale_override_call"
I've checked that cobalt is being called, I've tried restarting R, I've uninstalled and reinstalled the cobalt package, and even sent the code chunk to a friend who's able to run it fine. But I can't get it to run without the error. Any ideas what's wrong here?
match_data <- matchit(
union_member ~ gender + past_union_member + family_income,
data = labor_white,
method = "nearest",
distance = "mahalanobis",
estimand = 'ATT',
ratio = 1,
replace = TRUE)
summary(match_data)
mah_bal <- bal.tab(
match_data,
un = TRUE,
binary = 'std',
data = labor_white
)
love.plot(mah_bal)
Try upgrading your R version to 4.3.3. Was getting this error and it fixed it for me. If that doesn't work, I'd uninstall and reinstall the package and then R.