-
-
Notifications
You must be signed in to change notification settings - Fork 190
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Issue post-processing model with with Cox family type #1580
Comments
Strange. Which version of the splines2 package are you using? Perhaps they have changed the object class names? |
Okay, I can confirm that problem starts with splines2 version > 0.5.0. In the previous version I had (0.4.7) things were just working. Changing object class names is really not a good thing to do in any package... I will fix it in brms soon. |
Should now be fixed. |
Hi @paul-buerkner! First, thank you for your work on this! I have run into an issue similar to what's been described above. I am trying to calculate a Bayes Factor comparing the likelihood of the data under a null vs. alternative hypothesis using 2 Cox (survival) models. Using the bayes_factor() function, I am seeing the same error message described by @colinorourke above:
A similar reprex to the above reproduces this error:
All of my packages/software are up to date: Could this be an object class names issue? |
Update to the latest github version of brms |
Updated to brms: version 2.20.15 using: if (!requireNamespace("remotes")) { Re-ran all models above, and the error persists... |
Did you restart R? |
Ooooof! That worked! Thank you so much, @paul-buerkner! Appreciate your time! |
I've been working with a model fitted using the "cox" family type. It works great, but most functions such are predict, log_lik, conditional_effects, etc. don't seem to work with models of this type. I'm not sure, but this seems to be because the
bhaz_basis_matrix
function is checking for objects of classmSpline
, but the class of an object create by themSpline
function from thesplines2
package seems actually to beMSpline
.A reprex for this error follows:
Created on 2024-01-06 with reprex v2.0.2
The text was updated successfully, but these errors were encountered: