I have a very simple and small dataset (see attached) for which I want to fit a power law. The model runs through without any errors, everything seems to look fine but the model fit itself. It does not at all fit the data. I think the error has to do with the scales of x and y since for another dataset, the same call works just fine and produces good results.
prior1 <- c(set_prior('normal(0, 5)', nlpar = "a"),
set_prior('normal(1, 0.5)', nlpar = "b", lb = 0))
fit_test <-
brm(
bf(
median_rating ~ a * num_saturation100 ^ b ,
a + b ~ 1,
nl = TRUE
),
data = df_test,
save_all_pars = T,
sample_prior = 'yes',
warmup = 2000,
iter = 7000,
cores = 4,
control = list(adapt_delta = 0.96, max_treedepth = 15),
prior = prior1,
)
plot(conditional_effects(fit_test ), points = TRUE)
- Operating System: macOs Mojave
- brms Version: brms_2.12.0
Thanks in advance for your help!
test_dataset.csv (112 Bytes)