stan-dev / stan

Stan development repository. The master branch contains the current release. The develop branch contains the latest stable development. See the Developer Process Wiki for details.
https://mc-stan.org
BSD 3-Clause "New" or "Revised" License
2.6k stars 370 forks source link

How to use stan::math::hypergeometric_2F1 in stan? #3253

Closed MSQ-123 closed 10 months ago

MSQ-123 commented 10 months ago

I was trying to call my stan model by using rstan in R. It seems like stan does not has built-in hypergeometric_2F1 function. This function is only available in stan math. Is there any way to import stan math function directly into stan model? thanks a lot!

WardBrian commented 10 months ago

There is an open issue about exposing this function to the language here: https://github.com/stan-dev/stanc3/issues/1285

Further discussion should be had there. I believe the only thing preventing it was some questions for the implementer @andrjohns.

If you'd like to use it in the mean time, you could likely use RStan's ability to use "external" C++