Live data from Hacker News

Introduction to Zipline: A Trading Library for Python

quantinsti.com

111–120 of 155 posts

Re: Introduction to Zipline: A Trading Library for Python

#111
post #48
post #40

Earlier quoted context omitted.

Could you explain why you feel that it is better? What in particular does LEAN support that Zipline does not support?

Two features of LEAN won me over are : 1) LEAN supports finer data such as minutes, seconds, and ticks. 2) LEAN was developed in C#, which is way faster than Python.

At first glance you would think that python would be slower than C#; however, all of the real computation is happening in Numpy (C), Pandas (Cython which compiles to C), or in our own Cython. The extra overhead of the python is mainly dominated by the array computations happening in C or the IO of loading data.

Re: Introduction to Zipline: A Trading Library for Python

#112

I've typed and deleted this post a few times trying to find a way that it doesn't sound kind of pompous but if it helps save one person alot of money then screw it, I'll sound pompous.... I get asked quite a bit on how to start doing algorithmic trading and the first thing I always tell people is don't. I think I've said this many times now but the number of people who come at it with the thinking "I'm a computer sci…

You're pretty much spot on sans the "clean market data" part. I work for a very large electronic trading firm (and have been in HFT professionally the past 8.5-9 years of my career) who has a team dedicated to just grooming this data. It is a lot of work and it is noisy. Coming from some exchanges, it is even often wrong. Look at the entire mess the recent leap second did to some exchanges.

Re: Introduction to Zipline: A Trading Library for Python

#113
post #112

I've typed and deleted this post a few times trying to find a way that it doesn't sound kind of pompous but if it helps save one person alot of money then screw it, I'll sound pompous.... I get asked quite a bit on how to start doing algorithmic trading and the first thing I always tell people is don't. I think I've said this many times now but the number of people who come at it with the thinking "I'm a computer sci…

You're pretty much spot on sans the "clean market data" part. I work for a very large electronic trading firm (and have been in HFT professionally the past 8.5-9 years of my career) who has a team dedicated to just grooming this data. It is a lot of work and it is noisy. Coming from some exchanges, it is even often wrong. Look at the entire mess the recent leap second did to some exchanges.

I think you misunderstood, or I wasn't clear:)

The reason they have clean data is that big firms have teams of people dedicated to just cleaning data.

The little guy has to spend time cleaning data even before he/she starts to compete.

Re: Introduction to Zipline: A Trading Library for Python

#114
post #40

Earlier quoted context omitted.

Could you explain why you feel that it is better? What in particular does LEAN support that Zipline does not support?

Equities, FOREX, Futures, Options; tick, second, minute, hour and daily resolutions. Python, C# and F# backtesting. Dozens of models for improving the accuracy of your backtest. Live trading on IB, Tradier, FXCM, Oanda and paper trading. Local charting built in for desktop and backtesting. Lots of tools provided for free data downloads to work with public free data libraries. lean.quantconnect.com (I'm founder of QC…

It is a little disingenuous to say that zipline doesn't support python, the short description from github says: "Zipline, a Pythonic Algorithmic Trading Library". Zipline also supports equities at minute and daily frequencies. There is no charting built into zipline itself but tearsheets and graphs can be generated with pyfolio (a project by the same people as zipline). Zipline also comes with the ability to pull pricing and splits data from quandl and yahoo.

I realize I can't win you over but I wanted to present a fair comparison for others ;)

Also, I work on zipline

Re: Introduction to Zipline: A Trading Library for Python

#115
post #87

Earlier quoted context omitted.

In fairness, if someone told me they were going to make a killing on free webmail supported by ads and data mining, I think "How on earth do you intend to complete with Google?" would be a perfectly legitimate question.

In fairness, by that logic nothing would ever get done. Microsoft? You're never going to win over IBM. Xerox? You'll always be ancillary to Kodak. GM? Ford is already there. The Fugger's Banking company? Good luck against the Venetians and the Florentines. Same old story. At the end of the day, you either try something new or you don't.

Only if they don't have a good answer to the question.

Re: Introduction to Zipline: A Trading Library for Python

#116

Earlier quoted context omitted.

My thoughts are that if you use either platform for anything other than entertainment you're a fool. Seriously, here's your competition: https://en.wikipedia.org/wiki/Renaissance_Technologies How deluded do you have to be to think you have an edge over that?

This level of defeatism is the exact reason I got into the markets algo trading. People like you stay out. More to the point, just because a genius mathematician and code breaker started a hedge fund it doesn't at all push out any of the little guys. The market is so large he can't possibly be trading all instruments at once, and "scaling" is a problem for huge hedge funds. Especially ones that have to answer to thei…

Comparative advantage. Even if they're absolutely better than you at every possible strategy, there are still going to be opportunities in markets that it isn't worth their time to invest in.

Re: Introduction to Zipline: A Trading Library for Python

#117
post #11

Earlier quoted context omitted.

I don't know anything about algorithmic trading, but I'm just wondering, are the people who do make money lots of money out of it, those who have servers close to the data source, who do high frequency trades.

You can make money having by having better access like the HFT firms or by having data not widely available. You can also make money by applying well known principles more intelligently than others. This latter approach usually requires a lot of money. You can't afford retail brokerage costs when you're in a highly crowded and competitive trade. The best way to make some money as a personal trader is to take advantag…

Can you give an example of the kind of trade you can make in that kind of market? Doesn't matter if it's an old one, I'm just curious where to start looking.

Re: Introduction to Zipline: A Trading Library for Python

#118

Earlier quoted context omitted.

and I think the lack of this perpetuates market inefficiencies. I think insights into CDS can be a leading indicator into equities and equity futures, yet CDS are restricted to OTC markets in the US anyway, I'm sure this is its own discussion

CDS isn't an OTC instruments. Swaps are now traded on SEFs like MarketAxess or TradeWeb. Just because you don't have access to the data don't think that professionals don't. But this isn't OHLC data for listed equities. Expect to pay. Actually high quality realtime equity data (ITCH,PITCH,OpenBook Ultra,etc...) costs real money as well. Checkout CDS and FI market data offerings: https://www.marketaxess.com/data/marke…

That is awesome

Yeah i get the promise: professionals do this, pay a premium for that

Until they don't because someone provides the data for free or next to nothing

In this town we call it disruption

Re: Introduction to Zipline: A Trading Library for Python

#119
post #108

Earlier quoted context omitted.

My thoughts are that if you use either platform for anything other than entertainment you're a fool. Seriously, here's your competition: https://en.wikipedia.org/wiki/Renaissance_Technologies How deluded do you have to be to think you have an edge over that?

This isn't true. There are a non-zero number of traders who use IB and post positive returns. For example Taaffeite Capital Management (who gained some publicity for good returns on Brexit) are a Sure, bigger funds have better market access, and it will always be impossible to implement a high frequency trading approach. But these platforms are about as good as a small player can get. [1] http://www.afr.com/personal-…

Dr. Lun has a PhD from MIT and is doing original AI research. If that's your profile then do what you want=)

Re: Introduction to Zipline: A Trading Library for Python

#120
post #92

I've typed and deleted this post a few times trying to find a way that it doesn't sound kind of pompous but if it helps save one person alot of money then screw it, I'll sound pompous.... I get asked quite a bit on how to start doing algorithmic trading and the first thing I always tell people is don't. I think I've said this many times now but the number of people who come at it with the thinking "I'm a computer sci…

As long as the target you're optimizing for is different than what those 100 of PhD's (and most of the market) are optimizing for then maybe you've got a chance. You also don't need to pay their salary. So I agree wrt/ to longer time periods. Most of those PhD's are probably trying to predict minute to minute moves, or daily moves. A lot of them would be out of a job if they lose over 90 day periods. Not sure how muc…

> I would suspect the machine answer to this question would be something like P/E is lower so it's a good investment but who knows. So I agree with the economic/market insight comment as well.

This is spot on (tried it once :).

ML doesn't really help much at the macro level. MPT, perhaps combined with some decent economic insight, is a lot more useful.

Post reply on HN