Highest high for specific bars - easylanguage code suggestion - EasyLanguage Programming | futures io social day trading
futures io futures trading


Highest high for specific bars - easylanguage code suggestion
Updated: Views / Replies:603 / 24
Created: by cactus1973 Attachments:3

Welcome to futures io.

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

futures io is the largest futures trading community on the planet, with over 100,000 members. At futures io, our goal has always been and always will be to create a friendly, positive, forward-thinking community where members can openly share and discuss everything the world of trading has to offer. The community is one of the friendliest you will find on any subject, with members going out of their way to help others. Some of the primary differences between futures io and other trading sites revolve around the standards of our community. Those standards include a code of conduct for our members, as well as extremely high standards that govern which partners we do business with, and which products or services we recommend to our members.

At futures io, our focus is on quality education. No hype, gimmicks, or secret sauce. The truth is: trading is hard. To succeed, you need to surround yourself with the right support system, educational content, and trading mentors – all of which you can find on futures io, utilizing our social trading environment.

With futures io, you can find honest trading reviews on brokers, trading rooms, indicator packages, trading strategies, and much more. Our trading review process is highly moderated to ensure that only genuine users are allowed, so you don’t need to worry about fake reviews.

We are fundamentally different than most other trading sites:
  • We are here to help. Just let us know what you need.
  • We work extremely hard to keep things positive in our community.
  • We do not tolerate rude behavior, trolling, or vendors advertising in posts.
  • We firmly believe in and encourage sharing. The holy grail is within you, we can help you find it.
  • We expect our members to participate and become a part of the community. Help yourself by helping others.

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

 
 3  
 
Thread Tools
 

Highest high for specific bars - easylanguage code suggestion

 
Canicattì Italy
 
Trading Experience: Intermediate
Platform: Multicharts
Favorite Futures: Currency Fututres, crude oil
 
Posts: 15 since Nov 2018
Thanks: 0 given, 0 received

Highest high for specific bars - easylanguage code suggestion

Hello, everyone,
I am not very experienced with easylanguage, I have difficulty in coding the command to find highest (high, 5) only among the previous bars that have a minimum lower than the level x.

I hope I have explained well, I also enclose an image for more clarity. The result should return the maximum of bar A.

Anyone have any suggestions?

Thank you in advance

Gioak

Attached Thumbnails
Highest high for specific bars - easylanguage code suggestion-b.png  
 
 
Quick Summary
Quick Summary Post

Quick Summary is created and edited by users like you... Add FAQ's, Links and other Relevant Information by clicking the edit button in the lower right hand corner of this message.

 
 
Legendary  Vendor: www.abctradinggroup.com 
Hamburg Germany
 
Trading Experience: Advanced
Platform: Multicharts, Tradestation
Broker/Data: DTN IQ
Favorite Futures: ES
 
Posts: 2,054 since Apr 2013
Thanks: 360 given, 1,297 received


Hi Gioak,

I would suggest looking into the "for loop" as you will have to cycle through the previous bars and only include those that are lower than X in your tracking of the highest high.

Regards,

ABCTG

 
 
Canicattì Italy
 
Trading Experience: Intermediate
Platform: Multicharts
Favorite Futures: Currency Fututres, crude oil
 
Posts: 15 since Nov 2018
Thanks: 0 given, 0 received

Yes, but unfortunately I don't know how to select only the bars with the minimum lower than x.

Gioak

 
 
Legendary  Vendor: www.abctradinggroup.com 
Hamburg Germany
 
Trading Experience: Advanced
Platform: Multicharts, Tradestation
Broker/Data: DTN IQ
Favorite Futures: ES
 
Posts: 2,054 since Apr 2013
Thanks: 360 given, 1,297 received

Hi Gioak,

post the code you have for the loop and I am sure someone can point you in the right direction.

You might want to take a look at the free EasyLanguage Essentials PDF that you can find on the net. It will explain the basis and cover loops, too.

Regards,

ABCTG


cactus1973 View Post
Yes, but unfortunately I don't know how to select only the bars with the minimum lower than x.

Gioak


 
 
Canicattì Italy
 
Trading Experience: Intermediate
Platform: Multicharts
Favorite Futures: Currency Fututres, crude oil
 
Posts: 15 since Nov 2018
Thanks: 0 given, 0 received

HI ABCTG,

Thanks for your suggestions, I'll try to examine the free EasyLanguage Essentials PDF.

The code should be something like this:

Var: x(0), y(0);
For x = 1 to 5 and for y = 5 downto 1 begin

IF L [x] < x and H [x] = highest(high,y) then A = H [x] ;
end;

The problem is that I can't find the highest(high) only among the bars that have a minimum < than x.

Regards
Gioak

 
 
Legendary  Vendor: www.abctradinggroup.com 
Hamburg Germany
 
Trading Experience: Advanced
Platform: Multicharts, Tradestation
Broker/Data: DTN IQ
Favorite Futures: ES
 
Posts: 2,054 since Apr 2013
Thanks: 360 given, 1,297 received

Hi Gioak,

you can access the value for some reserved words like High by using a number within square brackets. Where the number specifies how many bars back from the currently processed bar you want to look at (while 0 is the most recent bar). Then you can compare this High and check it it matches your condition and only store it within a variable if it matches your condition and is higher than the currently stored value within the variable.

Regards,

ABCTG

 
 
Canicattì Italy
 
Trading Experience: Intermediate
Platform: Multicharts
Favorite Futures: Currency Fututres, crude oil
 
Posts: 15 since Nov 2018
Thanks: 0 given, 0 received

HI ABCTG,
thanks for the suggestions, my difficulty is in finding the correct criterion to distinguish first only the bars that have a minimum of less than x and then be able to find among them (only among them) the bar with the highest max.

Regards
Gioak

 
 
Legendary  Vendor: www.abctradinggroup.com 
Hamburg Germany
 
Trading Experience: Advanced
Platform: Multicharts, Tradestation
Broker/Data: DTN IQ
Favorite Futures: ES
 
Posts: 2,054 since Apr 2013
Thanks: 360 given, 1,297 received

cactus1973,

I would suggest to start simple. Create a loop that simply finds the highest high over the last X bars, without using the highest high function. You would use a variable to store the highest high within the loop in, by checking if the High for the bar you are currently looking at is higher than the value stored in the variable. If it is, you update the variable, if if's not, you do nothing. The only thing to add would be to reset the variable each time before you start with the loop (for example by setting the variable value to -999999 to ensure that it can be updated to a new high and that you don't store old information in the variable).

Regards,

ABCTG


cactus1973 View Post
HI ABCTG,
thanks for the suggestions, my difficulty is in finding the correct criterion to distinguish first only the bars that have a minimum of less than x and then be able to find among them (only among them) the bar with the highest max.

Regards
Gioak


The following user says Thank You to ABCTG for this post:
 
 
Canicattì Italy
 
Trading Experience: Intermediate
Platform: Multicharts
Favorite Futures: Currency Fututres, crude oil
 
Posts: 15 since Nov 2018
Thanks: 0 given, 0 received


HI ABCTG,
I think that highest high of x bars back is not useful, you don't need to know highest high unless it has a minimum lower than x.
Infact what you need to know with a loop from 0 to 5 is which lows are lower than X and then among them which one has the highest maximum, it will be A like pic. Between the 5 bars back there could be a higher high than A but if it doesn't have a minimum lower than x I don't care.

Regards,

Gioak

Attached Thumbnails
Highest high for specific bars - easylanguage code suggestion-abc.jpg  

 



futures io > > > > > Highest high for specific bars - easylanguage code suggestion
Thread Tools



Upcoming Webinars and Events (4:30PM ET unless noted)
 

futures io is celebrating 10-years w/ over $18,000 in prizes!

Right now
 

Thanks for everything -- $250 in Amazon Gift Cards ready to give away

Right now
 

Journal in July -- over $2,500 in prizes w/NinjaTrader

July
     

Similar Threads
Thread Thread Starter Forum Replies Last Post
Converting EasyLanguage Code to Thinkscript Code (TOS) joeking ThinkOrSwim 2 November 21st, 2017 08:04 AM
Highest bar between 20 and 40 bars ago DavidBodhi NinjaTrader Programming 5 August 25th, 2017 02:35 PM
Efficient Code for finding highest high and lowest lows of a range of bars. xigreek NinjaTrader Programming 18 July 31st, 2015 02:54 PM
highest bar close occuring within the last X number of bars . . . . jmejedi NinjaTrader Programming 37 October 6th, 2014 12:52 AM
Specific Scan for high volume, down bars waterwater ThinkOrSwim 1 May 23rd, 2014 01:10 AM


Tags
abc, buy, code, coding, dow, easylanguage, for loop, how to, indicator, indicators, information, lookback, ma, marketposition, metastock, multicharts, neoticker, new high, setstoploss, signal, stoploss, strategy, tradestation, txt, update, values, variable

All times are GMT -4. The time now is 10:44 AM. (this page content is cached, log in for real-time version)

Copyright © 2019 by futures io, s.a., Av Ricardo J. Alfaro, Century Tower, Panama, +507 833-9432 WhatsApp Business, 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