Pairs-Trading-With-Python icon indicating copy to clipboard operation
Pairs-Trading-With-Python copied to clipboard

trading size must be an integer

Open chunlexiong opened this issue 1 year ago • 1 comments

Thanks for the very nice tutorial notebook. I have learned a lot from it.

It is very good for beginners to capture the basic idea. However, when I think in a more practical point of view, I notice that one important thing has been ignored in the strategy: most likely the price ratio is not an integer. But in the strategy, you use the ratio as the number of contracts/shares to trade for S2. We cannot trade a portion of contract or share, can we?

chunlexiong avatar May 21 '24 12:05 chunlexiong

Hello. You should be able to trade portion sizes. If that isn't possible with the code, I'll make amendments soon.

Best, Andre

KidQuant avatar Mar 30 '25 00:03 KidQuant