At various times users on the forum ask about Bubble’s ability to perform complex math. Generally, the answer is that you need to access an external API that does that for you.
I recently ran across this article on R-Bloggers re “Integrating R with production systems using an HTTP API”. It seems that this type of integration with Bubble would be quite feasible and would vastly improve the ability of Bubblers to create “analytic” apps.
Just a thought.