The hardware and bandwidth for this mirror is donated by dogado GmbH, the Webhosting and Full Service-Cloud Provider. Check out our Wordpress Tutorial.
If you wish to report a bug, or if you are interested in having us mirror your free-software or open-source project, please feel free to contact us at mirror[@]dogado.de.

opl_dt_c

library(OPL)

Introduction

The opl_dt_c function implements ex-ante treatment assignment using as policy class a 2-layer fixed-depth decision-tree at specific splitting variables and threshold values.

Usage

opl_dt_c(make_cate_result,z,w,c1=NA,c2=NA,c3=NA)

Output

The function performs the following steps: - Standardizes threshold variables to the [0,1] range. - Determines optimal policy assignment using a constrained decision tree approach. - Computes and reports key statistics, including welfare gains and percentage of treated units. - Generates a visualization of the optimal policy assignment.

Details

The opl_dt_c function follows these steps: 1. Standardizes selection variables. 2. Implements a grid search over threshold values. 3. Identifies the optimal constrained policy maximizing welfare. 4. Computes summary statistics and visualizes treatment assignment.

Example

# Example data
data_example <- data.frame(
  my_cate = runif(100, -1, 1),
  X1 = runif(100, 0, 1),
  X2 = runif(100, 0, 1),
  treatment = sample(0:1, 100, replace = TRUE)
)

# Run the decision tree-based policy learning function
opl_dt_c()

Interpretation of Results

References


This vignette provides an overview of the opl_dt_c function and demonstrates its usage for decision tree-based policy learning. For further details, consult the package documentation.

These binaries (installable software) and packages are in development.
They may not be fully stable and should be used with caution. We make no claims about them.
Health stats visible at Monitor.