ngreifer / WeightIt

WeightIt: an R package for propensity score weighting
https://ngreifer.github.io/WeightIt/
102 stars 12 forks source link

`method_user` and the example on the `KBAL` #62

Open BERENZ opened 3 months ago

BERENZ commented 3 months ago

The example for the KBAL includes the following lines

    if (is_not_null(focal))
      treat <- as.numeric(treat == focal)
    else
      stop("`estimand` must be \"ATT\" or \"ATC\".", call. = FALSE)

This results in an error message, as the 'is_not_null' function is not exported. Changing it to WeightIt:::is_not_null solves the problem.

ngreifer commented 3 months ago

Thank you so much, I'll make that change in the documentation!

BERENZ commented 3 months ago

You may also change devtools to remotes as it is now suggested way to install packages from GitHub and other repos.