I did not find a way to compare 2 models in the package.
I think that the ability to compare 2 fits of nested models using a Likelihood Ratio Test would be a nice feature to add.
I think that the way to do that properly would be to do it by parametric bootstrap (I would not put much faith in asymptotic tests in this context).
I would perform as follows:
extract the difference in logLik between the 2 fits -> diff_obs
simulate the data under the model 1
refit both models on these data
compute the difference in logLik -> diff_sim
redo 2 till 4 boot times (using the future backend for parallel processing)
The p-value would be classically (1 + sum(diff_obs >= diff_sim)) / (boot + 1)
I don't think that would be much work since a parametric bootstrap is already implemented to test for the coefficients.
What do you think?
Perhaps, it should be decomposed into a few functions.
For example having a method simulate() that we could call would be potentially useful for other applications too.
If you are interested, what is your bandwidth at the moment?
I could probably PR that but not immediately...
I did not find a way to compare 2 models in the package.
I think that the ability to compare 2 fits of nested models using a Likelihood Ratio Test would be a nice feature to add.
I think that the way to do that properly would be to do it by parametric bootstrap (I would not put much faith in asymptotic tests in this context). I would perform as follows:
boot
times (using the future backend for parallel processing) The p-value would be classically (1 + sum(diff_obs >= diff_sim)) / (boot + 1) I don't think that would be much work since a parametric bootstrap is already implemented to test for the coefficients.What do you think?
Perhaps, it should be decomposed into a few functions. For example having a method simulate() that we could call would be potentially useful for other applications too.
If you are interested, what is your bandwidth at the moment? I could probably PR that but not immediately...