Is it possible to pack log_lik/predict/fitted functions with the brmsfit object?

#1

As I understand from this tutorial, the required functions are searched in the environment where the object is called so I need some extra code to generate those whenever I load a given fit. I was wondering if there’s a way to make these functions a part of a single object which contains the brmsfit and otherwise behaves like it.

0 Likes

#2

You can pass the log_lik etc. functions to custom_family directly, which will then be stored inside the brmsfit object and automatically used.

1 Like