brms icon indicating copy to clipboard operation
brms copied to clipboard

Predict with a phylogenetic model for a new species with known phylogenetic position

Open loubar opened this issue 6 years ago • 5 comments

Would it be possible to implement a way of predicting from a phylogenetic model for a new species when it’s phylogenetic position is known? When sampling new levels, I would like to use the species' position in cov_ranef.

loubar avatar Jan 29 '19 11:01 loubar

Thanks for opening this issue.

Refers to discussion https://discourse.mc-stan.org/t/predict-with-a-brms-phylogenetic-model-for-a-new-species-with-known-phylogenetic-position/7480/

paul-buerkner avatar Jan 29 '19 11:01 paul-buerkner

I know you're super busy, but any development on this? I tried the newdata2 argument in predict(). I mentioned that on discourse here. The prediction ran, but it didn't seem to include the new covariance matrix in the predictions. Any suggestions on where to look to predict newdata that includes the use of a covariance matrix in Stan? Thanks :)

jonnations avatar Sep 15 '21 16:09 jonnations

This is not yet implemented. Sorry.

paul-buerkner avatar Sep 15 '21 22:09 paul-buerkner

Hello,

Is there any progress on this, or any way someone could help?

Thanks

lyinch avatar Nov 16 '21 10:11 lyinch

Implementing this is non-trivial and I don't have much time to work on complicated brms features these days. Eventually, it will have to be implemented in get_new_rdraws which you can find in https://github.com/paul-buerkner/brms/blob/master/R/prepare_predictions.R

paul-buerkner avatar Nov 16 '21 10:11 paul-buerkner