Finding Range over all bars in a chart for N periods...High to Lowest ???
  #1 (permalink)  
Old 01-27-2007, 10:44 AM
Currency Trader
 
Join Date: Sep 2006
Location: New Zealand
Posts: 4
Digs is on a distinguished road
Default Finding Range over all bars in a chart for N periods...High to Lowest ???

int limit, records, N=2;
int counted_bars = IndicatorCounted();
limit = Bars - counted_bars;
if ( counted_bars < 0 ) return(0);
if ( counted_bars ==0 ) limit=Bars-1;
double EUR;

for(int i = 0; i < limit; i++)
{
EUR = (iHigh("EURUSD", 0, i) - Low[iLowest("EURUSD", 0, MODE_LOW, N, i )] );

}

I am trying to find the range from the current bar high to the lowest low over N periods, Including current bar,,,the above does seam to work ??

Any ideas...
Reply With Quote
Reply

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
High/Low Breakout Scalper scorpion Trading Systems 94 01-29-2012 05:40 PM
MT4 Time frame - 10 M chart bnf Indicator Coding 2 07-07-2011 12:07 PM
daily HI Low to work on a D1 chart Village Fool Trading Systems 5 09-07-2010 02:45 PM
High/Low Difference Indicator DoxAdon MetaTrader and ZeroCode 0 12-19-2006 12:46 AM
Looking for Williams Percentage Range %R chart11610 Indicators 0 09-12-2006 10:25 PM


All times are GMT. The time now is 11:39 PM.

Registered members gain free access to online FOREX currency trading tools, foreign exchange software, Metatrader MT4/MT5 expert advisors, MT4 indicators and EAs. Register now