Skip to content
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

Invalid stanfit object produced from stan_betareg... stan_glm worked fine? #576

Open
SiegleJ798 opened this issue Oct 15, 2022 · 0 comments

Comments

@SiegleJ798
Copy link

Summary:

I cannot run stan_betareg. Checked that all y variables are in hte proper support and updated the package. Still doesnt work

Description:

Running :
model<-stan_betareg(
linformula,
link=c('logit'),
data=train ,
model = TRUE,
x = TRUE,
y = TRUE,
contrasts = NULL,
weights = Insured.Acres,
QR=TRUE,
refresh=0,
prior= normal(0,2),
prior_intercept = normal(0,2)
)

[linformula is defined using as.formula to be:
PercentLoss ~ LossRatio.11 + ZeroIndemnities.11 + LossRatio.15 +
ZeroIndemnities.15 + LossRatio.16 + ZeroIndemnities.16 +
LossRatio.41 + ZeroIndemnities.41 + LossRatio.51 + ZeroIndemnities.51 +
LossRatio.78 + ZeroIndemnities.78 + LossRatio.81 + ZeroIndemnities.81 +
LossRatio.91 + ZeroIndemnities.91 + prec + dday0C + dday10C +
dday30C + prec2 + weightCovLevel.84 + totalpolicies | totalpolicies +
weightCovLevel.84 ]

gets the error:

[1] "Error in sampler$call_sampler(args_list[[i]]) : Initialization failed."
[1] "error occurred during calling the sampler; sampling not done"
Error in check_stanfit(stanfit) :
Invalid stanfit object produced please report bug

RStanARM Version:

2.21.3

R Version:

4.2.1

Operating System:

Your operating system (e.g., OS X 10.11.3)
Bugdata.csv

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant