Skip to content

Modifying percent change calculation #15

@limnoliver

Description

@limnoliver

This is pointing @lukeloken to the changes that need to be made to calculate percent change. Becky, Luke, and I discussed modifying the % change calculation in the following ways:

  1. Keep as is (using random forest), but randomly withhold a subset of events to generate some uncertainty in the estimate. So, would need to add an internal loop here. Maybe randomly withhold 10% of before and after data, and do 10 iterations to generate the uncertainty?
  2. Use random forest to generate the top X predictors from both the before and after models (e.g., all unique variables of top five from before and after) to throw into a multiple linear regression. Do same event withholds to generate uncertainty in the estimate. Pull the top parameters from here, and add multiple linear regression below the RF models in the loop.
  3. Output both results, including model performance of before after models (which the pipeline currently does here).

Note that these calculations aren't made when there is no difference in residuals calculated in the above model, so any new variable calculations that are made need to be set to NA here (also, looks like there are lots of inefficiencies in this script, so feel free to clean that up, too :)).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions