Shaved Bar Indicator for Tradestation? - futures io
futures io futures trading



Shaved Bar Indicator for Tradestation?


Discussion in EasyLanguage Programming

Updated
      Top Posters
    1. looks_one lselalum with 8 posts (1 thanks)
    2. looks_two ABCTG with 4 posts (1 thanks)
    3. looks_3 kronie with 1 posts (0 thanks)
    4. looks_4 Quick Summary with 1 posts (0 thanks)
    1. trending_up 4,464 views
    2. thumb_up 2 thanks given
    3. group 3 followers
    1. forum 10 posts
    2. attach_file 0 attachments




Welcome to futures io: the largest futures trading community on the planet, with well over 125,000 members
  • Genuine reviews from real traders, not fake reviews from stealth vendors
  • Quality education from leading professional traders
  • We are a friendly, helpful, and positive community
  • We do not tolerate rude behavior, trolling, or vendors advertising in posts
  • We are here to help, just let us know what you need
You'll need to register in order to view the content of the threads and start contributing to our community.  It's free and simple.

-- Big Mike, Site Administrator

(If you already have an account, login at the top of the page)

 
Search this Thread
 

Shaved Bar Indicator for Tradestation?

(login for full post details)
  #1 (permalink)
Houston, Texas/USA
 
 
Posts: 5 since Jul 2013
Thanks: 1 given, 1 received

Hi all,

I have tried to code a Show Me alert that shows up when the close of the candle is within 5% of the high or low of the same candle. I thought I could modify the existing Doji "Show Me" but somehow I messed it up. The alert should ignore doji candles (open=close), and should not consider the other wick (ie. bull candle only checks the upper wick, bear candle only checks the lower wick. This indicator seems to exist in mq4 but I can't find it for Easy Language and cant seem to get it right.


If any of you have thoughts on how I could code this or have the code yourself I would really appreciate it.

Thanks from a Newbie!

Reply With Quote

Journal Challenge February 2021 results (so far):
Competing for $1500 in prizes from Topstep
looks_oneSBtrader82 's Trading Journalby SBtrader82
(152 thanks from 29 posts)
looks_twoJust BEING a Trader: Letting Go!!by iqgod
(110 thanks from 31 posts)
looks_3Wisdom is Emptinessby Mtype
(68 thanks from 25 posts)
looks_4Deetee’s DAX Trading Journal (time based)by Deetee
(31 thanks from 15 posts)
looks_5Journal for peanuts1956by peanuts1956
(23 thanks from 13 posts)
 
 
(login for full post details)
  #3 (permalink)
 
 
Posts: 2,230 since Apr 2013
Thanks: 409 given, 1,470 received


lselalum,

this should do what you have in mind or at least could be tweaked towards doing it:

 
Code
Inputs: 
	double Percent	( 5 );

Variables:
	double Percentage	( 0 );

once Percentage = Percent / 100 ;
	
//up bar
if Close > Open and Close >= ( High - ( High * Percentage ) ) then
	Plot1( Low );
//down bar
if Close < Open and Close <= ( Low + ( Low * Percentage ) ) then
	Plot2( High );
Regards,
ABCTG

Follow me on Twitter Reply With Quote
 
(login for full post details)
  #4 (permalink)
Houston, Texas/USA
 
 
Posts: 5 since Jul 2013
Thanks: 1 given, 1 received

ABCTG,

Thank you so much. I put the code in as is and it showed an alert (dot) on every single candle on the daily chart. Not sure what went wrong.

Any thoughts?



ABCTG View Post
lselalum,

this should do what you have in mind or at least could be tweaked towards doing it:

 
Code
Inputs: 
	double Percent	( 5 );

Variables:
	double Percentage	( 0 );

once Percentage = Percent / 100 ;
	
//up bar
if Close > Open and Close >= ( High - ( High * Percentage ) ) then
	Plot1( Low );
//down bar
if Close < Open and Close <= ( Low + ( Low * Percentage ) ) then
	Plot2( High );
Regards,
ABCTG


Reply With Quote
 
(login for full post details)
  #5 (permalink)
 
 
Posts: 2,230 since Apr 2013
Thanks: 409 given, 1,470 received

lselalum,

what symbol did you test? A bar closing within 5% from the high or 5% from the low is very common by the way. In fact I'd expect almost all bars to trigger this condition, expect the dojis that are ruled out in the code. Think about a bar that makes a high of 1000, as long as the close is within 50 points of the high your condition is valid.

Maybe you could clarify the condition you are looking for and give an example.

Regards,
ABCTG

Follow me on Twitter Reply With Quote
The following user says Thank You to ABCTG for this post:
 
(login for full post details)
  #6 (permalink)
Houston, Texas/USA
 
 
Posts: 5 since Jul 2013
Thanks: 1 given, 1 received

Excellent point

I think the filter here that makes them more rare is the close has to be in the direction of the bar. For instance, using your example of a high of 1000. The close would need to be between 95 to 100 points. It has to be in the direction of the bar for it to filter.

I tested USD/JPY on a daily chart, btw.

I hope my explanation helped to clarify things a bit.

Thanks again for the hel

Reply With Quote
 
(login for full post details)
  #7 (permalink)
 
 
Posts: 2,230 since Apr 2013
Thanks: 409 given, 1,470 received

lselalum,

can you show a picture of a bar you'd like to see labeled? The code checks for up bars or down bars, which is in the direction of the bar in my opinion.

Regards,
ABCTG

Follow me on Twitter Reply With Quote
 
(login for full post details)
  #8 (permalink)
Houston, Texas/USA
 
 
Posts: 5 since Jul 2013
Thanks: 1 given, 1 received

ABCTG,

Shaved Bars shown with blue dots.



Video:
Shaved Bars | Ninjacators.com

Reply With Quote
 
(login for full post details)
  #9 (permalink)
NYC + NY / USA
 
Experience: Advanced
Platform: "I trade, therefore, I AM!"; Theme Song: "Atomic Dog!"
Trading: EMD, 6J, ZB
 
kronie's Avatar
 
Posts: 798 since Oct 2009

take a snapshot and post a picture of what these bars look like to you.


perhaps we can identify them or associate them with other types already in evidence...


there are volume bars, and
there are skinny bars, and

there are fat bars, and

there are inside bars, and
there are outside bars, and
there are volume bars, oh, did I say that already?

Reply With Quote
 
(login for full post details)
  #10 (permalink)
Houston, Texas/USA
 
 
Posts: 5 since Jul 2013
Thanks: 1 given, 1 received


Thanks everyone,

Got it to work with some additional assistance.

In case anyone wants it here is the code:

__
Inputs: HighPct( .95 ), LowPct( .05 );
var: CloseNearHigh( false ), CloseNearLow( False );

CloseNearLow = Close <> Open and Close <= Range * LowPct + Low;
CloseNearHigh = Close <> Open and Close >= range * HighPct + low;

If CloseNearHigh then plot1( High,"",Green );
If CloseNearLow then plot1( Low,"",Red );

if CloseNearHigh then
Alert( "CloseNearHigh" )
else if CloseNearLow then
Alert( "CloseNearLow" ) ;
___

I would suggest changing the plot color as it currently shows up as the same color as the bar.

Reply With Quote
The following user says Thank You to lselalum for this post:
 
(login for full post details)
  #11 (permalink)
 
 
Posts: 2,230 since Apr 2013
Thanks: 409 given, 1,470 received

You are welcome. Great job.

Regards,
ABCTG

Follow me on Twitter Reply With Quote


futures io Trading Community Platforms and Indicators EasyLanguage Programming > Shaved Bar Indicator for Tradestation?


Last Updated on July 7, 2014


Upcoming Webinars and Events
 

NinjaTrader Indicator Challenge!

Ongoing
 

Journal Challenge w/$1500 prizes from Topstep!

February
 

Identifying Setups & Targets Using Profile Charts w/Trevor & Tradovate

Feb 25
 

Battlestations! Show us your trading desk - $1,500 in prizes!

March
     



Copyright © 2021 by futures io, s.a., Av Ricardo J. Alfaro, Century Tower, Panama, +507 833-9432, info@futures.io
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.
no new posts