PCR based on change in OI — Tradetron Community
← Community

PCR based on change in OI

Keyword help 1,431 views

Sumit Agarwal

Is any keyword to create strategy for PCR based on change in OI (Open Interest)

Abhijit Bhattacherjee

I am also looking for this option. I checked, but couldn’t find any mechanism to tracker change in PCR over a period of time during the day.

Tradetron Team Tradetron team

There is a PCR keyword, but no keyword for change in OI, and no history of PCR during the day.

What PCR gives you

PCR('NIFTY', <expiry>) returns the current Put-Call Ratio by open interest for the underlying and expiry you pick. It is one live number, so you cannot read “PCR 30 minutes ago” from it directly.

Tracking the change yourself

  1. Save PCR at a chosen moment in a runtime variable, e.g. pcr_start set to PCR(...). Runtime variables are written when a block’s leg is taken, so this works when the save happens in a block that trades (for example your first entry, or a Repair Once).
  2. Later, compare: PCR(...) - Get Runtime Number(pcr_start) >= Number(0.2).

If you need PCR built on change in OI (today’s OI minus yesterday’s), that is not available as a keyword. It needs custom Python, or a value calculated outside Tradetron and sent in through the API / webhook route.

Test in Live Offline. Keyword reference: Keyword Documentation — Tradetron

:sparkles: Answer written with AI from Tradetron docs (Oct 2026). Original replies are kept above. Spot something wrong? Reply below.