gavinsimpson / gratia

ggplot-based graphics and useful functions for GAMs fitted using the mgcv package
https://gavinsimpson.github.io/gratia/
Other
206 stars 28 forks source link

`appraise()` and `qq_plot()` need a `seed` argument and to run the RNG-using bits with that seed #286

Closed gavinsimpson closed 3 months ago

gavinsimpson commented 6 months ago

qq_plot() and hence appraise() uses the ideas of mgcv::qq.gam() to either generate uniform random variables and pass them through the CDF of the conditional distribution of Y, or simulates new data from the conditional distribution of Y. Both of these use calls to RNG-using functions.

To be consistent with other functions in {gratia} qq_plot() should gain a seed argument so the user can pass in a seed. appraise() should also gain this argument seed = NULL and pass it on to qq_plot().