32 Comments
User's avatar
Shiv Mhatre's avatar

Hey , I see your work on sensibull and also following you since few weeks I really wanted to learn how to build the strategies and work with algo , I'm seeking guidance from you , Tell me the whatever the books , course , articles from where I can learn , I'm just a intermediate in options. And want to update myself for better results. Right Now I just Know about technical analysis ( Chart Analysis) . No Coding knowledge. If you can give some time to guide me that will be great. Waiting for you reply….

Expand full comment
Raahi Bhushan's avatar

I dont know chart analysis :(

For algo its better to start learning a programming language. Python should be good for this purpose. Then you can start by automating some things which you follow while trading.

Then you will be able to create strategies which are operations heavy and can be coded.

Expand full comment
Shiv Mhatre's avatar

Hey Thank for your reply, we need only python or any other languages also like C , C++ or JAVA and secondly from where we can get knowledge of options that is needed to make strategies any resources or book recommendations?

Expand full comment
Raahi Bhushan's avatar

Python is better. Please go through zerodha varsity options module for basic options understanding.

Expand full comment
Shiv Mhatre's avatar

Great , Thank you so much for replies, Mean a lot 😀

Expand full comment
Nisarg Desai's avatar

Amazing work sir. I had a question and a suggestion:

Question: If you do both manual analysis and then execute via Algorithm. Doesn't it make it harder to handle because of human biases and also harder to backtest for a long period.

Suggestion: I am not sure if you use a spread while selling a chppy sideways market. If you don't then you can do something like make a 1-2-4 lots spread. When markets do make a big move they still mostly have to follow the 2 std deviation BB range so they do calm down usually. So in a 1-2-4 spread if markets hit your first position you can exit that and hold the other 2 further OTMs where the lots r more because it is more probable that it will not breach it. In which case you do cover some of the losses. This along with the trend following strategy you have could make risk management easier.

Thanks a lot for all the efforts you put. Looking forward to learning more and more.

Expand full comment
pronaww's avatar

please share your code and the hyper-parameters also so I can backtest on my side also

Expand full comment
Raahi Bhushan's avatar

We will soon be sharing the code.

Expand full comment
Shahroz's avatar

How are you going to mitigate the following problem in this? When market fells aggressively but recovers slowly?

Spot Action Qty Comment

24990 BUY 1 lot 75 market fell by a gap of more than 10

24970 BUY 1 lot 150 market fell by a gap of more than 13

24940 BUY 1 lot 225 market fell by a gap of more than 17

24951 SEL 1 lot 150 recovers by +10

24962 SEL 1 lot 75 recovers by +10

24973 SEL 1 lot 0 recovers by +10

Total Profit = (951 - 940) + (962 - 970) + (973 - 990)

= (11) + (-8) + (-17)

= -14

Expand full comment
Raahi Bhushan's avatar

Even the sell will have the same multiplier as buy.

Also the algo buys max 1 this is to ensure that the position is a credit position to take theta gain.

Expand full comment
Shahroz's avatar

ok cool, thanks for the answer!

Expand full comment
User's avatar
Comment deleted
Aug 23
Comment deleted
Expand full comment
pronaww's avatar

Spot Action Qty Comment

24990 BUY 1 lot 75 market fell by a gap of more than 10

24970 BUY 1 lot 150 market fell by a gap of more than 13

24940 BUY 1 lot 225 market fell by a gap of more than 17

24951+7 SEL 1 lot 150 recovers by +17

24962+10 SEL 1 lot 75 recovers by +20

24973+13 SEL 1 lot 0 recovers by +23

Total Profit = (951+7 - 940) + (962+10 - 970) + (973+13 - 990)

= (11+[7]) + (-8+[10]) + (-17+[13])

= -14+[30] = 16

can you confirm this?

Expand full comment
Shahroz's avatar

here we are trading on future, and market open price is 25000

Expand full comment
Shahroz's avatar

The Algo says that it works on selling future or selling call option. Why only bearish? May be its by mistake, even if I assume its a PUT sell you're talking about. Then what would you buy when market falls? Its a bit confusing.

Expand full comment
Raahi Bhushan's avatar

It works for any option contract for which it has been activated. So it sell CE or buy PE when market goes up. And do reverse, buy CE and sell PE when market moves down.

Expand full comment
Shahroz's avatar

How do you manage position sizing for selling options? Any consideration around total margin to be used?

Expand full comment
Raahi Bhushan's avatar

To have atleast 3x magin available on Monday morning, for deployed margin in next week expiry.

Expand full comment
Dineshvallapureddy's avatar

Can you please share the link for code/repo

Expand full comment
Raahi Bhushan's avatar

Here is the repo link, we will keep adding more Lagos here.

https://github.com/Raahi-Bhushan/trading-algo

Expand full comment
Santhosh Kumar's avatar

As of 7th Aug, there was a huge downtrend and complete reversal. You should have started with extractor strategy. At what point (Nifty spot) did your savior strategy triggered identifying its a trending move on one side?

Expand full comment
Raahi Bhushan's avatar

I take 2 points into consideration -

1. My open positions. For that expiry place where delta really starts moving into -1800 and +1800 zone.

2. Supports and resistances of NIFTY, and then figure a point where I should say that it is a trending move.

As there was full recovery yesterday the trending move algo which is Survivor code gave loss and wave extractor gave profits.

Expand full comment
Santhosh Kumar's avatar

Thanks Ji. Does your algo calculates delta or you track it manually?

Expand full comment
Raahi Bhushan's avatar

It calculates it. Python has a library called mibian which does the calculation in the code.

Expand full comment
Santhosh Kumar's avatar

Great Ji. Is there any other option greeks that you use in your program, apart from delta?

Expand full comment
Raahi Bhushan's avatar

I don't think I calculate any other greek right now.

Expand full comment
tanmay's avatar

his Algo has survived the date 07-08-2025 this is beyond my imagination with this crazy move of both side and +0.5 % profit This is amazing

Expand full comment
Raahi Bhushan's avatar

Thanks buddy, main reason for this was that I do not trade 0dte. Because of which I did not take any loss in this week.

Expand full comment
tanmay's avatar

Yes i saw keep growing your capital ✅👍

Expand full comment
V-S's avatar

This is part gamma scalping (without the delta balancing act). Let’s think of a gamma scalping strategy!

Expand full comment
Raahi Bhushan's avatar

I am not sure if it is gamma scalping. Will read more about it. Do you know more gamma scalping strategy?

Expand full comment
V-S's avatar
Aug 7Edited

Have some idea of a textbook example. Buy x lots of straddle. Your starting delta is 0. If underlying goes up, your delta will increase. As soon as the delta touches 1 (note that max delta in this case is +|- x for this strategy), short 1 lot of future bringing delta back to 0. Short another when delta touches 1 again (upto a certain limit which i do not know how to define, but perhaps till x). When the starting point is reached, close the short futures. Similarly, long futures when underlying goes down. Challenge with this strategy is that it cannot be done with small capital and the bigger challenge is fighting all that theta. So there is also a variant with short straddles but well, naked straddles are to be avoided. So we can think of wide iron flies instead but i do not know how it plays out.

Expand full comment
Raahi Bhushan's avatar

Hmm k, didnt get it full...but will read more about it.

Expand full comment