NexusFi: Find Your Edge


Home Menu

 





Help with Scanner


Discussion in ThinkOrSwim

Updated
      Top Posters
    1. looks_one JBottum with 1 posts (0 thanks)
    2. looks_two Smiling trader with 1 posts (0 thanks)
    3. looks_3 ColoradoCliff with 1 posts (0 thanks)
    4. looks_4 sgtrades19 with 1 posts (0 thanks)
    1. trending_up 1,960 views
    2. thumb_up 0 thanks given
    3. group 4 followers
    1. forum 2 posts
    2. attach_file 0 attachments




 
Search this Thread
  #1 (permalink)
sgtrades19
Naperville, IL
 
Posts: 4 since Jan 2021
Thanks Given: 1
Thanks Received: 1

Hi Everyone,

I recently came across a code which plots strong low points of a stock, in different time frames. I'm trying to make a scanner but not having any luck. Can anyone please help? Ideally, I'd like to find stocks that are 1-2% away from the low on the "Monthly" aggregation period. Please see code below:

#DailyCOHL_Lines

input aggregationPeriod = AggregationPeriod.MONTH;
input showOnlyLastPeriod = yes;

plot DailyLow = low(period = aggregationPeriod);

DailyLow.SetDefaultColor(Color.RED);
DailyLow.SetPaintingStrategy(PaintingStrategy.HORIZONTAL);

plot ystdLow = low(period = aggregationPeriod)[1];

ystdLow.SetDefaultColor(Color.RED);
ystdLow.SetPaintingStrategy(PaintingStrategy.HORIZONTAL);

Thank you so much!


Reply With Quote

Can you help answer these questions
from other members on NexusFi?
No book, only a stair: journaling fills where price move …
Cryptocurrency
EA
Platforms and Indicators
My Rant with AMP Futures
Trading Reviews and Vendors
Datafeed for Atas
Platforms and Indicators
requesting .nrd replay files from 2026 spy and qqq
The Elite Circle
 
Best Threads (Most Thanked)
in the last 7 days on NexusFi
Mes vs MNQ
6 thanks
NexusFi site changelog and issues/problem reporting
5 thanks
BERN ALGOS algo trading journal
3 thanks
TopStep Trader disappointment
2 thanks
Johnnys Journal
2 thanks
  #2 (permalink)
ColoradoCliff
Parker CO/USA
 
Posts: 22 since Jun 2017
Thanks Given: 0
Thanks Received: 5


sgtrades19 View Post
Hi Everyone,

I recently came across a code which plots strong low points of a stock, in different time frames. I'm trying to make a scanner but not having any luck. Can anyone please help? Ideally, I'd like to find stocks that are 1-2% away from the low on the "Monthly" aggregation period. Please see code below:

#DailyCOHL_Lines

input aggregationPeriod = AggregationPeriod.MONTH;
input showOnlyLastPeriod = yes;

plot DailyLow = low(period = aggregationPeriod);

DailyLow.SetDefaultColor(Color.RED);
DailyLow.SetPaintingStrategy(PaintingStrategy.HORIZONTAL);

plot ystdLow = low(period = aggregationPeriod)[1];

ystdLow.SetDefaultColor(Color.RED);
ystdLow.SetPaintingStrategy(PaintingStrategy.HORIZONTAL);

Thank you so much!

You actually need to modify this study and instead of plotting the monthly lows, plot whether the % between current price & last month's low is within your threshhold...then you can scan as you're basically looking for true/false conditions.

Here's the code you can use for a custom scan. Be sure to set the Timeframe for your study scan to Monthly and enter this for your custom code...

plot MonthlyLowPct = absValue(1-(close/ low[1]) < .02);


Reply With Quote
  #3 (permalink)
 JBottum 
Omaha + Nebraska/USA
 
Experience: Intermediate
Platform: TOS
Trading: ES
Posts: 8 since Jul 2018
Thanks Given: 1
Thanks Received: 6



sgtrades19 View Post
Hi Everyone,

I recently came across a code which plots strong low points of a stock, in different time frames. I'm trying to make a scanner but not having any luck. Can anyone please help? Ideally, I'd like to find stocks that are 1-2% away from the low on the "Monthly" aggregation period. Please see code below:

#DailyCOHL_Lines

input aggregationPeriod = AggregationPeriod.MONTH;
input showOnlyLastPeriod = yes;

plot DailyLow = low(period = aggregationPeriod);

DailyLow.SetDefaultColor(Color.RED);
DailyLow.SetPaintingStrategy(PaintingStrategy.HORIZONTAL);

plot ystdLow = low(period = aggregationPeriod)[1];

ystdLow.SetDefaultColor(Color.RED);
ystdLow.SetPaintingStrategy(PaintingStrategy.HORIZONTAL);

Thank you so much!

Unfortunately you can't scan for multiple aggregation periods within the same scan study code.
We can likely use some sort of indicator separately on the scan screen to get you what you need.
Add me via         if you'd like to work on this.


Reply With Quote




Last Updated on August 31, 2021


© 2026 NexusFi®, s.a., All Rights Reserved.
Av Ricardo J. Alfaro, Century Tower, Panama City, Panama, Ph: +507 833-9432 (Panama and Intl), +1 888-312-3001 (USA and Canada)
All information is for educational use only and is not investment advice. There is a substantial risk of loss in trading commodity futures, stocks, options and foreign exchange products. Past performance is not indicative of future results.
About Us - Contact Us - Site Rules, Acceptable Use, and Terms and Conditions - Downloads - Top
no new posts