{"id":31211502,"url":"https://github.com/cyberagentailab/dte-ml-adjustment","last_synced_at":"2025-09-21T05:28:41.135Z","repository":{"id":241513690,"uuid":"805189191","full_name":"CyberAgentAILab/dte-ml-adjustment","owner":"CyberAgentAILab","description":"Code for \"Estimating Distributional Treatment Effects in Randomized Experiments: Machine Learning for Variance Reduction\"","archived":false,"fork":false,"pushed_at":"2024-05-27T05:15:50.000Z","size":5229,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-09-10T07:42:51.564Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"R","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/CyberAgentAILab.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-05-24T04:12:10.000Z","updated_at":"2024-11-29T04:30:51.000Z","dependencies_parsed_at":"2024-05-28T21:04:31.129Z","dependency_job_id":"171ee36f-9c5d-42ba-9edc-74ebf46f2412","html_url":"https://github.com/CyberAgentAILab/dte-ml-adjustment","commit_stats":null,"previous_names":["cyberagentailab/dte-ml-adjustment"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/CyberAgentAILab/dte-ml-adjustment","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CyberAgentAILab%2Fdte-ml-adjustment","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CyberAgentAILab%2Fdte-ml-adjustment/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CyberAgentAILab%2Fdte-ml-adjustment/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CyberAgentAILab%2Fdte-ml-adjustment/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/CyberAgentAILab","download_url":"https://codeload.github.com/CyberAgentAILab/dte-ml-adjustment/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CyberAgentAILab%2Fdte-ml-adjustment/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":274496640,"owners_count":25296422,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-09-10T02:00:12.551Z","response_time":83,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-09-21T05:28:38.648Z","updated_at":"2025-09-21T05:28:41.129Z","avatar_url":"https://github.com/CyberAgentAILab.png","language":"R","funding_links":[],"categories":[],"sub_categories":[],"readme":"\n## Estimating Distributional Treatment Effects in Randomized Experiments: Machine Learning for Variance Reduction\nThis repository contains code to replicate the experimental results from \"Estimating Distributional Treatment Effects in Randomized Experiments: Machine Learning for Variance Reduction.\"\n\n### Folders \n\n1. `data` folder includes files to create dataset used for empirical application from [Ferraro \u0026 Price (2013)](https://direct.mit.edu/rest/article-abstract/95/1/64/58053/Using-Nonpecuniary-Strategies-to-Influence). Download original data from https://dataverse.harvard.edu/dataset.xhtml?persistentId=doi:10.7910/DVN1/22633\u0026version=1.1 and save `090113_TotWatDat_cor_merge_Price.dta` file in data folder.\n\n2. `experiment` folder contains all R files used for analysis\n\n### Experiment Files \n\n1. `functions.R` file includes all necessary functions\n\n2. `run_simulation.R` includes code to run the Monte Carlo simulations and saves results as .rds files\n\n3. `compute_stats.R` includes code to calculate evaluation metrics (e.g. bias, RMSE) from the saved simulation results (.rds files) and saves them as .csv files\n\n4. `plot_figures.R` includes code to load the .csv files and plot figures for the simulation study\n\n3. `experiment_water_consumption.R` includes code to replicate the analysis of experimental data from Ferraro \u0026 Price (2013)\n\n### Instructions\n\n1.  Install all necessary packages in R\n2.  To replicate the results from the\n    Monte Carlo simulation, run the files in the following order: (1) `run_simulation.R`, (2) `compute_stats.R`, (3) `plot_figures.R`. The outputs will be figures appeared in Figures 1, 3 and 4 in the paper. \n3.  Run `experiment_water_consumption.R` to replicate the results from the water consumption experiment. The output will be figures appeared in\n    Figure 2 in the paper.\n    \n### R version and attached packages\n- R version 4.3.1\n\n- `RColorBrewer_1.1-3` `ggpubr_0.6.0`       `fastglm_0.0.3`      `bigmemory_4.6.1`    `xgboost_1.7.5.1`    `foreign_0.8-84`     `ggplot2_3.4.3` `dplyr_1.1.2`  `doParallel_1.0.17`    `glmnet_4.1-8`         `Matrix_1.6-1.1` `doMC_1.3.8` `iterators_1.0.14`     `foreach_1.5.2`        `grf_2.3.1` `randomForest_4.7-1.1` `gridExtra_2.3`  `tidyr_1.3.0` `haven_2.5.3` `readr_2.1.4`     \n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcyberagentailab%2Fdte-ml-adjustment","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcyberagentailab%2Fdte-ml-adjustment","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcyberagentailab%2Fdte-ml-adjustment/lists"}