rmweather0.2.63 package

Tools to Conduct Meteorological Normalisation and Counterfactual Modelling for Air Quality Data

base-functions

Pseudo-function to re-export functions from the stats package.

dplyr-functions

Pseudo-function to re-export dplyr 's common functions.

pipe

Pseudo-function to re-export magrittr 's pipe.

rmw_calculate_model_errors

Function to calculate observed-predicted error statistics.

rmw_clip

Function to "clip" the edges of a normalised time series after being p...

rmw_do_all

Function to train a random forest model to predict (usually) pollutant...

rmw_find_breakpoints

Function to detect breakpoints in a data frame using a linear regressi...

rmw_model_nested_sets

Function to train random forest models using a nested tibble.

rmw_model_statistics

Functions to extract model statistics from a model calculated with `rm...

rmw_nest_for_modelling

Function to nest observational data before modelling with rmweather .

rmw_normalise_nested_sets

Function to normalise a variable for "average" meteorological conditio...

rmw_normalise

Function to normalise a variable for "average" meteorological conditio...

rmw_partial_dependencies

Function to calculate partial dependencies after training with rmweath...

rmw_plot_importance

Function to plot random forest variable importances after training by ...

rmw_plot_normalised

Function to plot the meteorologically normalised time series after `rm...

rmw_plot_partial_dependencies

Function to plot partial dependencies after calculation by `rmw_partia...

rmw_plot_test_prediction

Function to plot the test set and predicted set after `rmw_predict_the...

rmw_predict_nested_partial_dependencies

Function to calculate partial dependencies from a random forest models...

rmw_predict_nested_sets_by_year

Function to make predictions by meteorological year from a random fore...

rmw_predict_nested_sets

Function to make predictions from a random forest models using a neste...

rmw_predict_the_test_set

Functions to use a model to predict the observations within a test set...

rmw_predict

Function to predict using a ranger random forest.

rmw_prepare_data

Function to prepare a data frame for modelling with rmweather .

rmw_train_model

Function to train a random forest model to predict (usually) pollutant...

system_cpu_core_count

Function to return the system's number of CPU cores.

wday_monday

Function to get weekday number from a date where 1 is Monday and 7...

zzz

Squash the global variable notes when building a package.

An integrated set of tools to allow data users to conduct meteorological normalisation and counterfactual modelling for air quality data. The meteorological normalisation technique uses predictive random forest models to remove variation of pollutant concentrations so trends and interventions can be explored in a robust way. For examples, see Grange et al. (2018) <doi:10.5194/acp-18-6223-2018> and Grange and Carslaw (2019) <doi:10.1016/j.scitotenv.2018.10.344>. The random forest models can also be used for counterfactual or business as usual (BAU) modelling by using the models to predict, from the model's perspective, the future. For an example, see Grange et al. (2021) <doi:10.5194/acp-2020-1171>.

  • Maintainer: Stuart K. Grange
  • License: GPL-3 | file LICENSE
  • Last published: 2025-08-22