开发者

How do I run simulations on rails? (e.g. sports/stock market/etc)

开发者 https://www.devze.com 2023-03-12 13:15 出处:网络
I\'m interested in creating some web apps that simulate results based on data. 开发者_运维百科For example, a baseball or stock market simulation, but I mostly have experience creating social apps/widg

I'm interested in creating some web apps that simulate results based on data. 开发者_运维百科For example, a baseball or stock market simulation, but I mostly have experience creating social apps/widgets in rails.

Any ideas of some resources I could check out? I've been looking through google, and theres some physicsy offline ruby stuff, but I'm still a bit lost.

I would imagine I'd have to aggregate a lot of statistical data, and then run it through various simulation algorithms.

I'd appreciate a push in the right direction, thanks for your help!


For one thing, Rails is designed to mostly do its computing between a web request and response, so you could use something like a queue or a daemonizer to run your simulations in the background.

For another, Rails is light on routines for numerical computing, so you could use ruby-gsl, a ruby port of the GNU Scientific Library. There are lots of goodies in there for simulators, including the standard statistics routines and support for the Monte Carlo algorithm.

0

精彩评论

暂无评论...
验证码 换一张
取 消