Period Range

Here you can post and download custom indicators. PLEASE: Do not start topics unless you are posting your own indicator, they will be moved to appropriate section even if you do.

Moderator: admin

Period Range

Postby Apprentice » Mon Jun 03, 2013 12:10 pm

ap.png

Indicator Will show percent position of the closing price within the range for last N periods,
which have preceded.
PR.lua
(3.04 KiB) Downloaded 848 times


The indicator was revised and updated
User avatar
Apprentice
FXCodeBase: Confirmed User
 
Posts: 36476
Joined: Thu Dec 31, 2009 11:59 am
Location: Zagreb, Croatia

Re: Period Range

Postby sho-me-pips » Wed Jun 26, 2013 12:39 pm

Would you modify this indicator or create a new indicator. Scale the numbering from 50% as 0.

100% = 10
0% = 10

I believe the math is: if > 50% (50%-PR)/PR*10 elseif < 50% -(50%-PR)/PR*10

Thank you in advance. This has been a very useful indi so far...
"A hundred pips a day keeps the collector away"
User avatar
sho-me-pips
 
Posts: 82
Joined: Sat Sep 11, 2010 8:38 am

Re: Period Range

Postby Apprentice » Fri Jun 28, 2013 2:26 am

Your request is added to the development list.
User avatar
Apprentice
FXCodeBase: Confirmed User
 
Posts: 36476
Joined: Thu Dec 31, 2009 11:59 am
Location: Zagreb, Croatia


Re: Period Range

Postby sho-me-pips » Sun Jun 30, 2013 11:25 pm

The formula works perfectly in excel.

You are correct, after looking closely at the formula, these are the changes I made and it is working perfectly.

Code: Select all
Central[period]=((source.close[period]-min) /((max-min)/100));
 end
 
 if Central[period] > 50 then
 Central[period]=((Central[period]-50)/50*10)
 elseif  Central[period]< 50  then
 Central[period]=((50-Central[period])/50*10)
 end


Thank You Very much...
"A hundred pips a day keeps the collector away"
User avatar
sho-me-pips
 
Posts: 82
Joined: Sat Sep 11, 2010 8:38 am

Re: Period Range

Postby Apprentice » Wed Jul 03, 2013 2:37 am

Upper indicator is updated according to the new formula.
User avatar
Apprentice
FXCodeBase: Confirmed User
 
Posts: 36476
Joined: Thu Dec 31, 2009 11:59 am
Location: Zagreb, Croatia

Re: Period Range

Postby Apprentice » Mon Sep 02, 2013 4:00 am

Use Last Period, parameter introduced.
If set to Yes, the current period is used in the calculation.
User avatar
Apprentice
FXCodeBase: Confirmed User
 
Posts: 36476
Joined: Thu Dec 31, 2009 11:59 am
Location: Zagreb, Croatia

Re: Period Range

Postby Alexander.Gettinger » Thu Sep 26, 2013 11:52 am

MQL4 version of Period range oscillator: viewtopic.php?f=38&t=59589.
Alexander.Gettinger
FXCodeBase: Confirmed User
 
Posts: 3785
Joined: Wed Mar 31, 2010 9:40 pm
Location: Russia, Omsk

Re: Period Range

Postby Apprentice » Fri Jun 09, 2017 7:33 am

The indicator was revised and updated.
User avatar
Apprentice
FXCodeBase: Confirmed User
 
Posts: 36476
Joined: Thu Dec 31, 2009 11:59 am
Location: Zagreb, Croatia


Return to Custom Indicators

Who is online

Users browsing this forum: No registered users and 65 guests