This is an old version, view current version.

13.6 User-defined function with _log suffix

Deprecated: A user-defined function ending in _log can be used in sampling statements, with

y ~ foo(...);

having the same effect as

target += foo_log(y, ...);

Replacement: Replace the _log suffix with _lpdf for density functions or _lpmf for mass functions in the user-defined function.

Scheduled Removal: Stan 2.32

Note: Following Stan 2.32, users can stil define a function ending in _log, it will just no longer have a special meaning or support the ~ syntax.