hte_plot_line {htetree}R Documentation

Visualize the Estimated Results

Description

The function hte_plot_line takes a model created by causal tree, as well as the adjusted version, and plots the different least squares models used to estimate heterogeneous treatment effects(HTE) at each node. At each node, this visualization aims to show how the estimated treatment effect differs when using ordinary least squares and weighted least squares methods. The weighted least squares method in this package uses inverse propensity scores as weights, in order to reduce bias due to confounding variables.

Usage

hte_plot_line(
  model,
  data,
  treatment_indicator = NULL,
  outcomevariable,
  propensity_score,
  plot.title = "Visualization of the Tree",
  gamma = 0,
  lambda = 0,
  ...
)

Arguments

model

a tree model constructed by hte_causalTree, hte_matchinleaves, or hte_ipw.

data

a data frame containing the variables in the model.

treatment_indicator

a character representing the column name for the treatment variable in the causal setup.

outcomevariable

a character representing the column name of the outcome variable.

propensity_score

a character representing the column name of the propensity score.

plot.title

character representing the main title of the plot.

gamma, lambda

numbers indicating the bias level used in sensitivity analysis

...

further arguments passed to or from other methods.

Value

No return value, used for plotting the estimated results with lines.


[Package htetree version 0.1.18 Index]