Cash Secured Put (CSP) Options Entry ScreenerCSP Options Entry Screener
This indicator screens stocks for a confirmed bullish DMI/ADX setup and flags them as candidates for **selling cash-secured puts (CSP)**. It is built to be used as a scanning column inside PulseWire's Pine Screener, across an entire watchlist.
WHY DMI/ADX FOR CSP ENTRIES
Selling a cash-secured put works best when you're comfortable owning the underlying at the strike price, and ideally you enter the trade right as the stock stops falling and starts to turn bullish again — rather than while it's still in a strong downtrend. Selling into an ongoing downtrend means a higher chance of assignment at a price that keeps falling further after you own the shares.
This screener uses the ADX/DMI crossover as a "trend is turning and starting to hold" signal:
ADX (trend strength) rising and holding above the -DI line for 2+ candles signals that downside momentum is fading and a new directional move is taking hold.
+DI above -DI at the same time confirms the emerging move is bullish, not another leg down.
In other words, the signal is not "buy the stock now," but "this stock just showed the first confirmed sign of turning bullish — a reasonable moment to consider selling a put" (at or below the current price, at a strike/expiry you're comfortable with). If the stock keeps rising, the put expires worthless and you keep the premium; if it pulls back and you get assigned, you're buying into a stock that had just shown a bullish trend reversal, at your chosen strike, rather than into an uninterrupted decline.
This does not replace your own judgment on strike selection, premium, or position sizing — it's a way to narrow a large watchlist down to symbols worth a closer look.
SIGNAL LOGIC
A signal fires when all of the following are true on a daily candle:
ADX is rising compared to the previous candle
ADX has been above the -DI line for at least 2 consecutive candles (confirms the trend is holding, not reacting to a single-bar spike)
+DI is above -DI at the same time (directional confirmation the move is bullish)
The signal fires only once, on the candle where the 2-day confirmation is met — it does not stay "on" for every following candle.
Note: all calculations are locked to the Daily timeframe internally (via `request.security` with `"D"`), regardless of the resolution the chart or the Pine Screener is currently displaying. This guarantees consistent daily-candle logic even when scanning on an intraday or weekly chart.
OUTPUT COLUMNS
Days since last Buy-Signal — candles since the last confirmed signal (0 = today, blank/na = never occurred). Main column to filter/sort on.
Price change today (%) — daily % change of the close vs. previous close (Data Window / Screener only, not plotted on the chart pane).
Price change since Buy-Signal (%) — % change of the close from the day of the last signal to today (Data Window / Screener only).
Buy Signal (today) — 1 if today is a signal candle, 0 otherwise.
ADX / +DI / -DI — current indicator values, for context.
On the price chart, a green "Sell CSP" label is plotted directly on the signal candle. In the DMI/ADX pane, a small green triangle ("Buy (day)") marks the same candle.
HOW TO SCAN THE LAST 5 DAYS IN THE PINE SCREENER
Add this script to any chart once (Pine Editor → Add to Chart) so it appears under "My Scripts."
Important: the Pine Screener only lists indicators that are in your Favorites — adding it to a chart alone is not enough. Open the Indicators dialog (or the script/column picker inside the Screener), find "CSP Options Entry Screener" under "My Scripts," and click the star icon to add it to your Favorites.
Open the Pine Screener (pulsewire.com/pine-screener/, or Products → Screeners in the web app — not yet available in the Desktop app).
Choose the watchlist you want to scan as your symbol source.
Click "Choose indicator" and select this script, "CSP Options Entry Screener," from your Favorites.
Open the "Days since last Buy-Signal" field and click "Manual setup...".
Filter it: less than or equal to 5 (≤ 5).
Sort ascending to see the newest signals first (0 = signal today, 1 = yesterday, etc.).
Optionally add "Price change today (%)" and "Price change since Buy-Signal (%)" as extra columns for context on how far the stock has already moved since the signal — useful for judging whether there's still room for a CSP entry or whether the move has largely played out.
This filter shows every symbol in your watchlist that had a confirmed bullish DMI/ADX reversal within the last 5 trading days — a shortlist of candidates worth evaluating for a cash-secured put.
Indicator






