Skip to content

plot_moderator functions #2

@eteitelbaum

Description

@eteitelbaum

Hi,

Thanks for the awesome package. I am having some problems getting plot_moderator_d() and plot_moderator_c_bin() to work. I am getting an error that says:

Error in plot_moderator_d(model_results, lalonde$educ) : 
  could not find function "plot_moderator_d"

For a reprex, I am just using the example from the documentation:

library(bartCause)
library(plotBart)

data(lalonde)
confounders <- c('age', 'educ', 'black', 'hisp', 'married', 'nodegr')
model_results <- bartCause::bartc(
 response = lalonde[['re78']],
 treatment = lalonde[['treat']],
 confounders = as.matrix(lalonde[, confounders]),
 estimand = 'ate',
 commonSuprule = 'none'
)
plot_moderator_d(model_results, lalonde$educ)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions