NexusFi: Find Your Edge


Home Menu

 





High/Low in Easy Language for Specific Time Frame


Discussion in EasyLanguage Programming

Updated
      Top Posters
    1. looks_one cnbcsucks with 7 posts (4 thanks)
    2. looks_two ABCTG with 3 posts (6 thanks)
    3. looks_3 MsTs with 1 posts (0 thanks)
    4. looks_4 Big Mike with 1 posts (0 thanks)
    1. trending_up 7,701 views
    2. thumb_up 12 thanks given
    3. group 4 followers
    1. forum 11 posts
    2. attach_file 4 attachments




 
Search this Thread

High/Low in Easy Language for Specific Time Frame

  #11 (permalink)
 ABCTG   is a Vendor
 
Posts: 2,436 since Apr 2013
Thanks Given: 484
Thanks Received: 1,629

cnbcsucks,

the code I posted below tracks the high and low within your time window and updates the plots to higher highs and lower lows. If you want to see a horizontal line at the highest high/lowest low you might want to use trendlines instead of plots and update the trendline with a change in your tracking variable.

Based on your screenshot I can't tell which code you are using exactly.

Regards,

ABCTG



cnbcsucks View Post
ABCTG, Thank you for replying. I tried the EL code on a 5 minute chart for SPY. Is it a formatting issue or is the code plotting highs/lows on each 5 minute bar from 5 - 6:30am? Please see posted chart. Possible to plot the low and high across the entire 5 - 6:30am pre-market window as drawn manually on chart with white line?
spy


Follow me on Twitter Reply With Quote
Thanked by:

Can you help answer these questions
from other members on NexusFi?
Quantum physics & Trading dynamics
The Elite Circle
Pivot Indicator like the old SwingTemp by Big Mike
NinjaTrader
static margin on the right side of a chart
NinjaTrader
NT7 Indicator Script Troubleshooting - Camarilla Pivots
NinjaTrader
Better Renko Gaps
The Elite Circle
 
Best Threads (Most Thanked)
in the last 7 days on NexusFi
Funded Trader platforms
29 thanks
The Trading Pit "Futures VIP" Account Journal
16 thanks
Spoo-nalysis ES e-mini futures S&P 500
16 thanks
GFIs1 1 DAX trade per day journal
15 thanks
Trading with Intuition
12 thanks
  #12 (permalink)
 ABCTG   is a Vendor
 
Posts: 2,436 since Apr 2013
Thanks Given: 484
Thanks Received: 1,629

cnbcsucks,

I just tested the below code again and it does not update the variables with every bar here, but only on bars that make a higher high or lower low.

 
Code
Variables:
bool doReset		( false ),
double preMarketHigh 	( -999999 ),
double preMarketLow 	( +999999 );

if Date <> Date[1] then //set flag on date change
   doReset = true ;

If time > 0830 and time < 0930 then
begin
	//reset the tracking values at the beginning of bracket
	if doReset then
	begin 
                doReset = false ;
  		preMarketHigh = High ;
  		preMarketLow = Low ;
        End ; 
	
	//keep track of higher highs and lower lows
	If High > preMarketHigh then
		preMarketHigh = High ;
		
	If Low < preMarketLow then
		preMarketLow = Low ;
End ;

If preMarketHigh <> -999999 then  
	Plot1( preMarketHigh , "Premarkethigh" ) ;
If preMarketLow <> +999999 then	
	Plot2( preMarketLow, "PreMarketLow" ) ;
Regards,

ABCTG

Follow me on Twitter Reply With Quote
Thanked by:




Last Updated on April 24, 2020


© 2024 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 - Privacy Policy - Downloads - Top
no new posts