Hacker News new | ask | show | jobs
by chollida1 4333 days ago
There was a company last week that showed off their bitcoin algos and I wrote a comment that basically said don't use them and I felt bad about it for the rest of the week. I'll try to just be positive here:)

To weigh in on the mention of using doubles for finance....

Using double for finance, perfectly fine. All trading systems I've seen use double, from HFT systems to deep learning AI systems that open and close potions over months. Double is fine for most algo trading, heck the exchanges and dark pools I've talked with use double.

What you can possibly do with this.

1) Learn how to write the logic of an trading algorithm.

2) learn the basics of technical trading, with MACD, Keltner channels, vortex and Bollinger band indicators. They've definitely put the time in to getting the indicators that FX traders like to use.

What you can't do with this system.

1) React to currency fluctuations on a tick by tick basis. FX is just so fast and precise, there is a reason that professional FX traders mix FX spot quotes from multiple sources, we use 4 at the fund I work at and some use up to 10 sources. There is also a reason why FX is quoted to 4 decimal places while equities are to 2, sometimes 3 for penny stocks.

2) Use this in a real world setting. I can't see any privacy policy or contract indicating what happens when shit goes wrong. We are talking about money here, you can't just half ass this kind of thing.

Plus they use FXCM which had this new out about them:

http://online.wsj.com/news/articles/SB1000142405270230425560...

> LONDON—Foreign-exchange trading firm FXCM Inc. FXCM +0.08% agreed to pay fines and refunds totaling almost £10 million ($16.7 million) to settle allegations by a U.K. financial regulator that the company withheld profits from clients and failed to inform British authorities that it was under investigation in the U.S.

> The Financial Conduct Authority said that U.K. units of FXCM withheld £6 million from customers on foreign-exchange transactions between August 2006 and December 2010. The regulator said the broker pocketed profits when exchange rates moved in its customers' favor while a trade was in process, but it passed on losses that occurred on other trades.

3 comments

A lean algorithm will comfortably execute every tick even in a busy market. Of course if it can't be processed before the next tick comes in, subsequent executions will run late, though we leave this up to the trader and hope to just provide the most performant execution environment we can.

We find no issues running scripts of reasonably high complexity. Of course if you have a particularly heavy algorithm it may be better suited to running at interval close.

With regard to legal position, you're absolutely right. While we're in beta you can connect to live broker accounts, though we are blocking order requests from actually being sent. We want to be water tight both technically and legally before we full launch with regulatory authorization, lifting this restriction and allowing real money to be risked.

As with brokers, we just want to support as many as we can. FXCM were a natural first choice for integration as they have excellent support for API solutions and have the most fully featured FIX implementation we've come across. Of course it's up to the trader to establish if any conflict of interest scenario exists between themselves and the broker.

If the algo falls behind, it's usually better to throw away intermediate data.
> [Can't] React to currency fluctuations on a tick by tick basis. FX is just so fast and precise.

I don't see any reason why they couldn't aggregate prices and compute them tick-by-tick? JavaScript can run really fast these days

> [Can't] Use this in a real world setting. I can't see any privacy policy or contract indicating what happens when shit goes wrong. We are talking about money here, you can't just half ass this kind of thing.

I mostly agree and I wouldn't use it, but if you're just starting out and can't afford to build your own platform, it might be worth considering?

> There is a reason that professional FX traders mix FX spot quotes from multiple sources, we use 4 at the fund I work at and some use up to 10 sources.

We use 15 :) (Although two are internal flow from other desks)

> Plus they use FXCM which had this new out about them

We use FXCM. If they quote and fill the best price, I don't really care how they arrived at it. But that's just me.

> There is also a reason why FX is quoted to 4 decimal places while equities are to 2, sometimes 3 for penny stocks.

Isn't the reason that most FX rates are O(1) (eg EURUSD is about 1.34, cable is about 1.7) whereas most stocks are O(10) or even O(100) and O(1000)?

If you take an FX rate that isn't O(1) eg USDJPY which is about 100, the convention is that it's quoted to 2 decimal places, like a stock (though there are some exceptions, eg USDMXN is around 13 but it's quoted to 4dp, and USDRUB is around 35 and also quoted to 4dp).

Stocks in the US are quoted to 2 decimal places because of reg NMS rule 612 (the subpenny rule). Any displayed quotes above $1.00 are priced in pennies and below $1 you can quote in increments of $0.0001. Trades can however happen in subpenny increments. For example retail internalizers may offer subpenny price improvement (e.g. market is 20.00 x 20.01 - retail market sell order gets filled at 20.0001). Also non-displayed bids and offers may exist at subpenny increments (e.g. market is 20.00 x 20.01 and there is a non-displayed midpoint peg buy at 20.005 at nasdaq - incoming marketable sell will match and print at 20.005).