Skip to content
Screening 2 min read

Write a custom stock scan with CleverScan

Write a stock idea as CleverScan rules, check them, run the scan, and refine the conditions.

Write and combine price, volume, and indicator rules in the CleverScan editor.

Start from a rule you can read aloud. Check it, run it, and change one condition at a time.

Step 01

Open the CleverScan Editor

Choose Research › CleverScan in the dashboard menu, or open the Screener and choose CleverScan under Scan method, then select Edit scan. Start from a featured scan or a template in the Scan Library beside the editor, or write your own rule. Your changes do not update the results until you select Run Scan.

Step 02

Write a rule you can read

Type the rule below. The first condition keeps stocks whose closing price is above their 50-session average; the second keeps stocks trading more shares than their 20-session average volume. The editor checks the expression as you type and points to anything it cannot run.

close > sma50 and volume > avgVol20
Step 03

Review, then run the scan

Before running, read each condition: the field, the comparison, and the number. Select Run Scan, compare the matching rows, and open a chart to explore a result. If a condition removes more stocks than you expected, change it and run the scan again.

Step 04

Group alternatives with parentheses

AND requires both conditions to hold. OR allows an alternative. Parentheses keep alternatives together, as in the rule below. Keep the logic easy to follow.

(exchange = "NYSE" OR exchange = "NASDAQ") AND close > sma50
Step 05

Add a supported indicator

The documented functions include SMA, EMA, RSI, ATR, and others. The rule below compares the closing price with a 50-session simple moving average.

close > SMA(50, close)
Step 06

Give the query a useful name

Save the expression after checking its output. Use a name that describes the conditions rather than a promised outcome. If you share the query, include its purpose and date in your own notes. The share link carries the expression and selected session, not your private account data.

Step 07

Define strong before ranking it

Strength can mean trend alignment, relative performance or unusual activity. Write one definition before choosing fields. The example combines price above a long-term average with an RS Rating threshold; it does not use RSI as a cross-stock strength ranking. Review each condition and compare an excluded boundary case.

close > sma200 and rsRating >= 80
Step 08

Preserve the logic you can explain

Read the expression as field, operator, unit and period. Group OR alternatives before joining them to shared AND conditions. Run the validated rule, inspect a match and a non-match, and save it with a descriptive name. A screen defines a population for research rather than establishing profitable trading results.

Read the CleverScan syntax reference

Read our data and methodology notes for calculation context. This guide explains research tools and observations. It does not recommend a trade or investment.

Follow your curiosity

One good question leads to another.

All guides
Make room for better research

Put your curiosity to work.

Build a scan with filters or CleverScan rules. Explore the results. Find your next idea.

Write a CleverScan rule