epiverse-trace / quickfit

[SUSPENDED] Toolbox of model fitting helper functions
https://epiverse-trace.github.io/quickfit/
Other
2 stars 1 forks source link

Removes dependencies on fitting pckages #6

Closed joshwlambert closed 1 year ago

joshwlambert commented 1 year ago

This PR tackles #5 and makes {quickfit} a more lightweight package.

The previous implementation of the multi_fitdist() function explicitly called the functions from {fitdistrplus} and {coarseDataTools}. The function provided a thin wrapper around functions from these packages and would have been unsustainable to develop as every new fitting function would require more developments, and new dependencies to the package. Therefore the developments in this PR have refactored the multi_fitdist() function to remove hard dependencies and instead take functions as input. This gives the user more flexibility and also provides easier development. The packages that were previously imported are now suggested because they are used in tests. As part of the refactoring the fit_cdt_dist() function became unnecessary and has been deleted.

For the same reasoning as above, the goodness_of_fit() function was a thin wrapper around fitdistrplus::gofstat() and has now been removed.

There are also minor updates to the calc_aic() and calc_bic() function and documentation.

jamesmbaazam commented 1 year ago

Hi @joshwlambert, I recognise that this PR has been open for a while now and needs to be merged asap. I will review it first thing tomorrow morning.