Hi,
please can anyone create code of the Projection Oscillator as it is done in thinkorswim? I do not have original code, but I am providing picture of the indicator with some values on it (please see attachment).
Thanks and best regards,
End Proctoring-
I think that this one should be the same: Projection Oscillator
Hello Nicolas, if you compare CCJ daily in proreal up to yesterday you are going to see difference (it is actually pretty large one) in way of plotting.
Merci,
P.S. this is about most that I know in French.
if you compare CCJ daily in proreal up to yesterday you are going to see difference (it is actually pretty large one) in way of plotting.
Most likely the data feed that you are using in ThinkOrSwim is not identical to the data feed to your PRT platform and if you don’t put the same thing in then you can’t expect to get the same thing out. If the indicator calculations are the same calculations then this can be the only reason for a difference in output.
P.S. French is not needed as you are in the English language forums and the rules say….
- Only post in the language of the forum that you are posting in. For example English only in the English speaking forums and French only in the French speaking forums.
Hello again,
thinkorswim is not really mine but of my friend. I did check all daily data between two platforms and they are identical, which means something in calculation slightly differ. I can see some similarities between oscillators but they are not matching for sure (please see pictures in the attachment of both platform indicators).
I will try to figure out mathematical model of the calculation and will post it here if I find it.
Thanks again and best regards,
The real formula used by TOS would be great. In the meantime, you can try this version I just coded by gathering ressource on the web:
period = 14
pboPeriod = 14//user defined, default is 14
price=customclose
mHigh = linearregression[period](high)[1] //returns the slope (m) of Linear Regresion
mLow = linearRegression[period](low)[1]
count = 0
pbw = 0
pu = 0
pl=0
for i = 0 to pboPeriod + 1 do //move back 1 period
hhigh = high[i]
llow = low[i]
vHigh = hhigh + (mHigh * (count))
vLow = llow + (mLow * (count))
if (vHigh > pu) then
pu = vHigh
endif
if (vLow > pl) then
pl = vLow
endif
count=count+1
next
PBO = 100 * (price - pl) / (pu - pl)
return pbo
Thanks Nicolas,
Actually after spending a bit more time with ProReal Projection Oscillator and analyzing it, I find it is quite better for entries than thinkorswim counterpart. Thanks a lot, I think ProReal PO(14) is keeper.
Best regards,
End Proctoring-