Range Rule bias RSI
Forums › ProRealTime English forum › ProBuilder support › Range Rule bias RSI
- This topic has 6 replies, 3 voices, and was last updated 1 year ago by yas.
-
-
12/13/2022 at 12:33 PM #205705
Hi Guys
Need bit of help on my code i am trying to code this indicator using RSI but i am getting the following error on the code when trying to upload to the pro real time
error is postive integer field expected with rsi
here is the code
12345678910111213141516171819202122232425262728293031323334353637383940414243444546//settingsrsiperiod=RSI[14](close)rsios=30//oversold levelrsiob = 80 //overbrought Levelrsisupport=40//rsi bulishsupport levelrsisell=60//rsi bearish support levelrsisellsup=50//rsi bear market support// end of settingsrangeBias = 0 //0=bullish, 1=strong bullish, 2=bearish, 3=strong bearishif rangebias=0 thenlo=40mid=60hi=80elsif rangebias=1 thenlo=54mid=65hi=85elsif rangebias=2 thenlo=35mid=55hi=75elsif rangebias=3 thenlo=30mid=50hi=70elselo=40mid=60hi=80endifsource=customcloseirsi=rsi[rsiperiod](source)if irsi<=lo thenr=0g=255elsif irsi <= mid thenr=255g=255elsif irsi <= hi thenr=255g=165elser=255g=0endifreturn irsi coloured(r,g,0)anyone can help please
12/13/2022 at 12:43 PM #20570612/13/2022 at 12:50 PM #205708You posted your request at 12:33, now it’s 12:43 and you are urging a reply.
You will get one, as soon as someone is available. Be patient, please 🙂
12/13/2022 at 12:51 PM #205709Hi,
Topic moved from french probuilder forum to english probuilder forum, to comply with forum rules in yellow box below, appearing just before the “submit” button.
You have this line:
1irsi=rsi[rsiperiod](source)requiring your rsiperiod to be an integer,
but at the beginning, it is defined as:
1rsiperiod=RSI[14](close)which is not an integer…
So depending on what you’re trying to achieve, either you make rsiperiod an integer to start with, or you use something else which is an integer in your irsi definition
12/13/2022 at 12:56 PM #205711The issue is in line 2, since is assigned an RSI value, instead of a number of periods.
It should read:
1rsiperiod=1412/13/2022 at 12:57 PM #205712Two replies in a row is better than one!
1 user thanked author for this post.
12/13/2022 at 1:02 PM #205713 -
AuthorPosts
Find exclusive trading pro-tools on