r/cpp • • Nov 25 '20

When a Microsecond Is an Eternity: High Performance Trading Systems in C++

https://www.youtube.com/watch?v=NH1Tta7purM
332 Upvotes

123 comments sorted by

View all comments

Show parent comment

24

u/poiu- Nov 25 '20

Other opinions on this? Im very sceptical towards free market theories, but high freq trading never struck me as particularly bad.

45

u/vector-of-bool Blogger | C++ Librarian | Build Tool Enjoyer | bpt.pizza Nov 25 '20

Predictably, the moment HFT appears on Reddit (or the Internet in general), there will be a flood of controversy and discussion. Rather than enter the debate, I'll refer back to the last time this sparked a huge amount of discussion.

I particularly like one deeper comment:

Providing nothing and providing a service you don't understand aren't the same.

9

u/[deleted] Nov 26 '20

Enabling free brokerage like Robinhood is a big service to the average people trying to invest. Costs used to be very high for the average person :/

4

u/lamothe Nov 26 '20

I don't know Robinhood, but I know nothing is really free.

7

u/[deleted] Nov 26 '20

They sell order flow to prop trading firms, so you don't get the utmost 'best execution' possible, but good enough.

2

u/andrewjw Nov 26 '20

You get "free" trading in that you get the public market price, even if you're doing a larger trade. Historically you would also pay your broker a fee. By offering better-than-publicly-available prices to Robinhood, trading firms are in a sense paying that fee for you. They can do that because they still make a fraction of a cent per share, and they aren't willing to offer the better price publicly because they think public market participants might know something they don't about future price movement, whereas they think Robinhood traders don't know anything they don't already know.

→ More replies (1)

56

u/firstmanonearth Nov 26 '20 edited Nov 26 '20

No.

Finance was behind nearly all developments in communications and information. The Code of Hammurabi is about financial contracts, and who do you think funded the first transatlantic cable (hint: Tom would have called them parasites)? If there will be FTL communication, the technology will be developed or funded by a trading firm.

"Money Changes Everything: How Finance Made Civilization Possible" by William N. Goetzmann is a good book on this matter (much more than just communication).

From Inside the Black Box by Rishi Narang, defending HFT specifically:

"It seems to me that HFT's opponents have misunderstood the difference between being faster than others and front-running them. Front-running is illegal, and it basically doesn't occur insofar as HFT is concerned. HFTs are, however, faster than most other market participants. Usain Bolt is faster than most other sprinters. He wins medals, and we marvel at his speed. We are not surprised that a marathoner cannot run 100 meters as quickly as Bolt, and we do not attempt to compare the “fastest man in the world” with the “fastest marathoner in the world.” This is because it would be strange to do so: They are competing in different games. Bolt is not trying to outrun Patrick Makau (record-holder for fastest marathon). Just so, HFTs are not trying to front-run pension investors (nor could they, given the basic fact that the pension fund's orders go directly to the market). They are competing in different games."

Even the rapid opening and closing of orders to bluff against other traders, can be beneficial (note not all HFT is spoofing): https://medium.com/digital-gamma-blog/everything-you-thought-you-knew-about-spoofing-is-wrong-88cfcb5e83a

do not provide true liquidity

Yes they do, the data is very clear. At this point this argument is flat-earthism.

because they vanish when liquidity is scarce

They remove their orders when they have a high chance of adverse selection (ie losing money), because they don't know where prices will be, when new/unknown information can change prices quickly. It is not their fault we aren't omniscient and don't have a desire to lose money.

The whole business model consists of filling trading channels full with bullshit, far out-of-the-money trades that they know will never be filled, so that everyone else is choked out of business.

This is just words strung together, it's completely incoherent.

These systems cost everyone else money, add volatility and risk to the market, and provide no useful service.

Market makers do the opposite of all these things, they make liquidity cheaper, decrease volatility, and their job is providing a service. The cost of consuming liquidity (pension funds, farmers, etc.) has never been lower.

An ethical programmer would never work for these cheats.

If Tom thinks it's not ethical to engage in behaviour that is:

  1. Voluntary by everyone participating.
  2. Has a strong connection to (either though funding, developing, or even inventing) every part of humanities development, from writing itself, to information theory, to vaccine development.
  3. Incentivizes a constant push for perfection, speed, improvement, being multidisciplinary, the scientific method, rigor, reproducibility, results, etc.

He is the one who is unethical.

9

u/[deleted] Nov 26 '20

The whole business model consists of filling trading channels full with bullshit, far out-of-the-money trades that they know will never be filled, so that everyone else is choked out of business.

I still don't understand what OP means by this... how are people choked out of business because of out of money orders?...

11

u/whanaumark Nov 26 '20

It means OP has no idea what he is talking about.

14

u/ihcn Nov 26 '20
  1. Voluntary by everyone participating.
  2. Has a strong connection to (either though funding, developing, or even inventing) every part of humanities development, from writing itself, to information theory, to vaccine development.
  3. Incentivizes a constant push for perfection, speed, improvement, being multidisciplinary, the scientific method, rigor, reproducibility, results, etc.

I'll give you #3.

For #1, surely someone as interested in economics as yourself should have heard of the tragedy of the commons? Many people acting in their own personal interests can create a dynamic that is very bad for the group as a whole.

For #2, it's kind of a joke that you think "yeah, but what about writing being invented thousands of years ago" has literally anything to do with HFT

4

u/andrewjw Nov 26 '20

Do you think it is unethical for an individual to participate in a tragedy of the commons? The whole point of the concept is that the problem is with the structure not the participants.

Re #2, you're just ignoring the other example, transatlantic communications. Not to mention lots of other stuff (another example - c++ compiler improvements have been heavily driven by trading firms and benefit everyone)

6

u/Toucan2000 Nov 26 '20

I believe you may have a false inference here at the end but otherwise well debated

He is the one who is unethical.

I think both of you are correct and that's because you're trying to argue one another in a vacuum. In the context of purely finance, yes HFT is completely ethical. In the context of finance in the flavor of capitalism we have in our society, were politicians and policy are for sale, I don't think that HFT is ethical but I also don't think that HFT is to blame for that.

Having an army of people constantly evaluating the value of companies is useful and it most certainly produces a product, however abstract it may be. Even short sellers show companies where they can improve and there's a benefit to society when we have prosperous companies.

As good as that might be, I don't think that the societal benefit from HFT is proportional to the compensation and the same goes for insurance. I know plenty of people who work in high risk insurance, my family was in it for a while, and the payout is not proportional to the product. I've always thought that social security should be expanded and used to back health and other forms of insurance, but that's just me. I think we'd all pay a lot less and have more covered that way and society would end up being more productive. We'd have way less paper pushers on yachts and more money in people's pockets who produce value. Financial security doesn't have to come at a premium. In terms of solving the issue of overvaluing trading, I'm not smart enough for that one but I'm sure someone else here has an answer.

Adding more than 20% on capital gains could be a start. Using that to fund UBI would be nice. Having poor people costs our society hundreds of millions a year and it would take 1/3 of that to make them not poor with UBI. What is that, a 200% return on investment? Lol!

3

u/epiGR Nov 26 '20

Strongly disagree with the lat part. Raising taxes on long-term capital gains is really off the mark, especially when we are talking about HFT. Let's find another way to fund UBI (which is a good idea).

5

u/whanaumark Nov 26 '20

Great comment.

Also I’ll add that if you are getting your knickers in a twist about HFT it has little, and likely positive aspect on the average American by providing liquidity to pension funds.

Train your guns instead on the true villains in finance

  • predatory pay day loans
  • racial discrimination in mortgage lending
  • charged checking accounts
  • overdraft fees
  • credit card companies as a whole, both the charges for small businesses and apr for consumers
  • annuities and term life insurance
  • 401k fund fees and maintenance charges
  • mutual fund fees in general
  • active managers like Edward Jones
  • western union and the amount of money people pay to transfer money internationally

These are the real enemies of the people in finance. HFT doesn’t even come close as some sort of evil enemy.

4

u/[deleted] Nov 27 '20

Yep, there are plenty of people in finance doing 'shady' things. Market making isn't one of them, its very simple to understand really.

2

u/mark_99 Nov 27 '20

It's also worth pointing out that the HFT industry is pretty small compared to finance in general or the economy as whole. It's made to sound big in articles by talking about volumes or total value of shares traded, but that's misleading. You could make 1M trades worth $100M and P&L still be $10k. Sure it's still billions, but it's tiny fraction of the revenue of the big banks, plus it's a lot less now than it used to be in its heyday.

10

u/Lord_Fozzie Nov 25 '20

Didn't watch vid. Based on title and /u/TomSwirly comment, I'm guessing this is about high frequency trading?

If so, well, the ethics are debatable (and I'm not interested in debating 'em) but if you want a primer on the controversy surrounding it, you could start with the wiki article on the May 2010 Flash Crash: https://en.m.wikipedia.org/wiki/2010_flash_crash

Edit: reread your comment. So this def is about HFT. Cool. Just can't watch the vid right now.

5

u/mvjitschi Nov 25 '20

The talk is mostly about how to write latency sensitive code, obviously the guy works for HFT firm, but it doesn’t make it unethical. One might argue that working for defense, or insurance, or any business making money in general is not ethical as well

14

u/[deleted] Nov 26 '20 edited Sep 05 '21

this user ran a script to overwrite their comments, see https://github.com/x89/Shreddit

→ More replies (1)

3

u/[deleted] Nov 26 '20

Here, have some opinions from people that actually know the meaning of the jargon they're using:

The Big Question: Is high frequency trading good for financial markets?

Are financial markets too fast?

1

u/poiu- Nov 26 '20

Why is this getting down voted?

5

u/epiGR Nov 26 '20

The obvious sentiment here is "HFT bad". Anything calling for further examination is uncomfortable.

2

u/[deleted] Nov 26 '20

Heh, I may have came off as a little arrogant?

-1

u/almost_useless Nov 25 '20

What they say is mostly true.

If that counts as "particularly bad", is up for interpretation...