NexusFi: Find Your Edge


Home Menu

 





Wick indicator/plot for Renko bars


Discussion in EasyLanguage Programming

Updated
      Top Posters
    1. looks_one Big Mike with 1 posts (0 thanks)
    2. looks_two cbritton with 1 posts (1 thanks)
    3. looks_3 Quick Summary with 1 posts (0 thanks)
    4. looks_4 RM99 with 1 posts (0 thanks)
    1. trending_up 7,627 views
    2. thumb_up 1 thanks given
    3. group 2 followers
    1. forum 3 posts
    2. attach_file 0 attachments




 
Search this Thread

Wick indicator/plot for Renko bars

(login for full post details)
  #1 (permalink)
 RM99 
Austin, TX
 
Experience: Advanced
Platform: TradeStation
Trading: Futures
Posts: 839 since Mar 2011
Thanks Given: 124
Thanks Received: 704

Below is the code for an indicator which will plot the wicks for Renko bars. It does not work historically, the wicks plotted for historical bars will either be zero/non-existant, or equal to the close of the previous bar.

It does however, plot live/forward making proper wicks for any bar created from live data.

Does anyone know how to create a numeric output from the truehigh and truelow values? I'm not very good at indicators yet, so I don't even know how the code specifies to plot on the bar chart, instead of making it's own/new section at the bottom.

I'd like to reference the truehigh (wick) and truelow (wick) values in number form to possibly craft some strategies. I realize they will not work in backtest, but I could run them forward for now.

Also, in the future, if there are some slick programmers here, we could possibly use a time based chart and reference bar time values to artificially recreate the wick values for historical/backtest purposes. I know TS will not backtest using a second data series, but I'm not sure if it may be possible to backtest using global dictionary or global variable values.

/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

Input: HighWickColor (Green);
Input: LowWickColor (Red);
var: IntraBarPersist True_High (0);
var: IntraBarPersist True_Low (0);
var: IntraBarPersist T_High_L (0);
var: IntraBarPersist T_Low_H (0);
var: Brick_Dir (0);

// BRICK DIRECTION
If BarStatus(1) = 2 then begin
If High > Open then Brick_Dir = 1;
If Low < Open then Brick_Dir = -1;
End;
// TRACK THE BRICK HIGH AND THE BRICK LOW
If Brick_Dir = -1 then begin
If Close <= Open[1] and Close >= Open then begin T_High_L = Close; T_Low_H = Close; End;
If Close < Open then begin T_Low_H = Close; T_High_L = Open; End;
If Close > Open[1] then begin T_Low_H = Open[1]; T_High_L = Close; End;
End;
If Brick_Dir = 1 then begin
If Close >= Open[1] and Close <= Open then begin T_High_L = Close;T_Low_H = Close; End;
If Close > Open then begin T_High_L = Close; T_Low_H = Open; End;
If Close < Open[1] then begin T_High_L = Open[1]; T_Low_H = Close; End;
End;
// TRACK THE TRUE HIGH AND THE YRUE LOW
If True_High < High then True_High = High;
If True_Low > Low then True_Low = Low;

Plot1(True_High, "BarHigh",HighWickColor ,0,0);
Plot2(T_High_L , "BarLow ",HighWickColor ,0,0);
Plot3(T_Low_H , "BarHigh",LowWickColor ,0,0);
Plot4(True_Low , "BarLow ",LowWickColor ,0,0);

// RESET
If BarStatus(1) = 2 then begin
True_High = Close;
True_Low = Close;
T_High_L = Close;
T_Low_H = Close;
End;
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

"A dumb man never learns. A smart man learns from his own failure and success. But a wise man learns from the failure and success of others."
Started this thread Reply With Quote

Can you help answer these questions
from other members on NexusFi?
NT7 Indicator Script Troubleshooting - Camarilla Pivots
NinjaTrader
Trader Dale [email protected] or Scammer Dale
Trading Reviews and Vendors
IQFeed MBO data experience
The Elite Circle
ISO Equity Curve Indicator
NinjaTrader
SPY ETF Question
Stocks and ETFs
 
Best Threads (Most Thanked)
in the last 7 days on NexusFi
Supertradersams Thread Journal on NQ/MNQ
27 thanks
GFIs1 1 DAX trade per day journal
24 thanks
Diary of a simple price action trader
17 thanks
Tao te Trade: way of the WLD
13 thanks
Deaddogs Stock Trading
12 thanks

(login for full post details)
  #3 (permalink)
 
cbritton's Avatar
 cbritton 
Atlanta, Georgia
 
Experience: Intermediate
Platform: NT
Broker: DDT
Trading: ZN, ZB
Posts: 230 since Mar 2010
Thanks Given: 152
Thanks Received: 256



RM99 View Post
Does anyone know how to create a numeric output from the truehigh and truelow values? I'm not very good at indicators yet, so I don't even know how the code specifies to plot on the bar chart, instead of making it's own/new section at the bottom.

I'd like to reference the truehigh (wick) and truelow (wick) values in number form to possibly craft some strategies. I realize they will not work in backtest, but I could run them forward for now.

From within your indicator you can reference the true_high and true_low from bars in the past.
i.e. True_High[3] would get that value 3 bars ago. But, like you said, you can only do this for charts that have been built in real time. I use commentary a lot to manually reference historical data on a bar by bar basis. Try adding this to your indicator right before the plot. Then use the Analysis Commentary to show the values in a dialog box for a selected bar.

 
Code
    #beginCmtry
        CommentaryCL("*************************************************");
        CommentaryCL("True High: ", True_High);
        CommentaryCL("True Low: ",True_Low);
        CommentaryCL("*************************************************");
    #End;
I hope this helps.

Regard,
-C

“Strategy without tactics is the slowest route to victory. Tactics without strategy is the noise before defeat.” - Sun Tzu
Reply With Quote
The following user says Thank You to cbritton for this post:
(login for full post details)
  #4 (permalink)
 
Big Mike's Avatar
 Big Mike 
Manta, Ecuador
Site Administrator
Developer
Swing Trader
 
Experience: Advanced
Platform: Custom solution
Broker: IBKR
Trading: Stocks & Futures
Posts: 50,232 since Jun 2009
Thanks Given: 33,103
Thanks Received: 101,344


cbritton View Post
From within your indicator you can reference the true_high and true_low from bars in the past.
i.e. True_High[3] would get that value 3 bars ago. But, like you said, you can only do this for charts that have been built in real time. I use commentary a lot to manually reference historical data on a bar by bar basis. Try adding this to your indicator right before the plot. Then use the Analysis Commentary to show the values in a dialog box for a selected bar.

 
Code
    #beginCmtry
        CommentaryCL("*************************************************");
        CommentaryCL("True High: ", True_High);
        CommentaryCL("True Low: ",True_Low);
        CommentaryCL("*************************************************");
    #End;
I hope this helps.

Regard,
-C

This must be something TradeStation specific as I've never heard of it before I wonder if there is a MultiCharts equivalent?

Mike

We're here to help: just ask the community or contact our Help Desk

Quick Links: Change your Username or Register as a Vendor


For the best trading education, watch our webinars
Searching for trading reviews? Review this list


Lifetime Elite Membership: Sign-up for only $149 USD
Receive exclusive offers from our Site Sponsors: Browse Offers
Report problems with the site: Using the NexusFi changelog thread
Follow me on Twitter Visit my NexusFi Trade Journal Reply With Quote





Last Updated on July 27, 2011


© 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