covid19br / nowcaster

Repository to the R package nowcaster, nowcasting with INLA
https://covid19br.github.io/nowcaster
GNU General Public License v3.0
17 stars 5 forks source link

Slope function to calculate the tendency of the curve #34

Open rafalopespx opened 2 years ago

rafalopespx commented 2 years ago

Through a simple linear model adjusted to the trajectories, we can infer the tendency of the epidemic curve, to do so we can construct functions that take the posteriors output from the main function nowcasting_inla and adjust the linear model and return the slope of the trajectories, to give a more quantitative tendency inference:

rafalopespx commented 2 years ago

Two functions needed, slope.estimate.quant, to receive trajectories and fit a linear model on it and return only the slope, and a generate.estimate.slope, which can uses internally the function and from it return a data.frame, with the statistics of this adjust over the trajectories