Hi,
Stupid question, probably. I apologise in advance. But it should be quick and painless to answer.
In the current installation of Pivot, I think Camarilla is perhaps wrong (which means this is not a stupid question) or it is correct and I am reading the LUA code incorrectly, hense the likely apology. here is my reference question.
I think the line below is a 'comment' (none functioning) line in the lua file.....because is it preceeded with two dashes '--' and is in green text in the lua file
normal text....
elseif CalcMode == O_CAM then
green text ...***-- P[period] = (ref.high[prev_i] + ref.close[prev_i] + ref.low[prev_i]) / 3;***
Then what follows is P[period] = ref.close[prev_i];
If I understand it, in this implementation Camilla is using the previous close as P. To check this I looked that the values of P (daily) and values of closing bar (opening bar 17:00) and the Camilla P value is indeed the same as ref.close[prev_i].
My understanding is that P value for Camilla =
-- P[period] = (ref.high[prev_i] + ref.close[prev_i] + ref.low[prev_i]) / 3; and not simply the closing value of the previous period/day. (like for some others).
If my reading is correct, could we please make it so that the Camilla P value is like those used for .....?
if CalcMode == O_PIVOT or CalcMode == O_FIB or CalcMode == O_FLOOR then
P[period] = (ref.high[prev_i] + ref.close[prev_i] + ref.low[prev_i]) / 3;
Or set me straight on what is happening...please? Patrick
CODE FROM LUA FILE:......
pday = prev_i;
if CalcMode == O_PIVOT or CalcMode == O_FIB or CalcMode == O_FLOOR then
P[period] = (ref.high[prev_i] + ref.close[prev_i] + ref.low[prev_i]) / 3;
elseif CalcMode == O_CAM then
-- P[period] = (ref.high[prev_i] + ref.close[prev_i] + ref.low[prev_i]) / 3; (this text is in green)
P[period] = ref.close[prev_i];