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

Feature Request: predict specific chains/iterations #12

Open
Pentaonia opened this issue Jun 15, 2023 · 0 comments
Open

Feature Request: predict specific chains/iterations #12

Pentaonia opened this issue Jun 15, 2023 · 0 comments

Comments

@Pentaonia
Copy link

Pentaonia commented Jun 15, 2023

Hi @vdorie,

In my process, I noticed that the predict function predicts my new data for every chain and every iteration - the burn-in. Wouldn't it be nice and much faster to be able to directly address a specific chain/all chains and maybe the last 200 iterations (or something else) that should be predicted?

Something like this:

model: chains = 6, iterations-burnin = 2500

predict.stan4bartFit(
        object = model,
        newdata = newdata_df,
        type = "ev",
        combine_chains = FALSE,
        pred_chains = c(2, 4, 6),
        pred_iter = 2300:2500
)

As I am quite busy at the moment, I am not able to look at your code and I don't know how "simple" can be realized, but from my "outside view" it might not be that difficult. Might it be "just" an implementation of how many iterations/chains are extracted from the model object and handled in the function!?

All the best
Louis

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