开发者

Building a stock market trading game in RoR, what libraries are available?

I'd like to build a relatively simple online stock trading application (in RoR). It would just be a game so no real trades- just an online simulation based on real market data.

A good example being http://www.wallstreetsurvivor.com/ or http://www.weseed.com/ (any ideas what libs / platforms they are using?)

There will be no CFD Trading, Spread Betting, Currency Trading or Fixed Odds. It will just be stock trading - using market / stop / limit orders.

Naturally, it will need to generate visualisations and pull in market data.

Can someone point me in the right direction regarding libraries (stuff like yahoo finance gem) / platforms I can use to get me started?

There seems to be some existing java platforms but they are very much geared towards single users.

Also, I'd much prefer to use Rails. If there's a real pro开发者_JAVA百科blem with this then I'd be open to switching platform/language.


A little searching reveals a handful of options (disclaimer: I haven't used any of these, so I can't vouch for them!).

For financial/stock data:

  • yahoo_stock gem -- interface to Yahoo! Finance API
  • ystock gem -- similar to above
  • ruby/finance -- lots of data-fetching options

For creating charts:

  • GoogleCharts gem -- interface to Google's chart API
  • gchart gem -- similar to above
  • rChart gem -- port of the pChart library

I would suggest some of your best places to search would be RubyGems.org and GitHub.com.


It's probably worth looking into JRuby, then you can mix Rails with any Java libraries you might need.


There are some code referece you will find in EclipseTrader for the same. I think you take the feed from real market and make order matching engine based on people order.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜