Expp1 prior on nu for Student's t

I’m trying to fit a simple Student-t model with an expp1 prior on \nu. With the following code

dat <- tibble(y = rt(n = 100, df = 5))

fit <-
  brm(data = dat,
      family = student,
      formula = y ~ 1,
      prior = c(prior(normal(0, 10), class = Intercept),
                prior(normal(0, 10), class = sigma),
                prior(expp1(1/10), class = nu)))

I get this error

Error in stanc(model_code = paste(program, collapse = “\n”), model_name = model_cppname, : failed to parse Stan model ‘file87f99d24c9’ due to the above error.

If I take the \nu prior out, the model runs fine. What am I missing?

Please also provide the following information in addition to your question:

  • Operating System: macOS High Sierra
  • brms Version: 3.4.0

expp1 is a function not a prior. I think you meant exponential(0.1).

Thanks for the clarification. You’re right, exponential(0.1) works fine. Is there a way to use the exponential + 1, though?

I would just do exponential(0.1) and then shift that parameter by one when you call brm.