Description Usage Arguments Value Examples
View source: R/plot_computed_cost_time.R
A plot that shows the number of average daily costs associated to a particular health event in function of time. The points represent the costs associated to the predicted average daily number of health events. The colours refer to the type of outcome.
1 | plot_computed_cost_time(computed_costs, plot_file)
|
computed_costs |
[data frame] A data frame containing the following variables: - ‘date': date of simulated day in format ’yyyy-mm-dd'; - 'event': name of the outcomes; - 'lower_individual_cost': lower bound of 95 associated to a particular health event; - 'fit_individual_cost': costs associated to the average daily number of a particular health event; - 'upper_individual_cost': upper bound of 95 associated to a particular health event. |
plot_file |
[chr] filename of the destination path. Format of image is automatically decided by the filename extension |
A plot with time trends of the costs associated to the average daily number of predicted ealth outcomes considered.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 | ## Not run:
library(imthcm)
default_models <- train_event_models(use_ita = TRUE)
hh_full_year <- predict_hm(models = default_models,
weather_history = test_weather,
weather_today = test_weather[c(726L, 729L, 731L), ],
full_year = TRUE
)
computed_costs <- compute_cost(hh_full_year, use_meps = TRUE)
plot_computed_cost_time(computed_costs,
plot_file = 'costs_trend_plot.png'
)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.