關于pivot函數疑問
作者:開拓者 TB 來源:cxh99.com 發布時間:2019年06月19日
-
咨詢內容:
我在寫雙頂,發現pivot函數有問題,對于如下語法。
Bool Pivot(NumericSeries Price,Numeric Length,Numeric LeftStrength,Numeric RightStrength,Numeric Instance,Numeric HiLo,NumericRef PivotPrice,NumericRef PivotBar)
即使我設置了LeftStrength=100,仍然能夠找到一個左邊僅僅大于幾根K線的峰值。很像是bug?
請問誰碰到過類似的問題?
For i_cnt = 1 To 5
? ?? ???{
? ?? ?? ?? ?DT = False;
? ? ? ? ? ? ? ? ? ? ? ? findprepivot = false;
? ?? ?? ?? ?findprepivot = Pivot(H,Lookback,PH_leftStrength,PH_rightStrength,i_cnt,1,PreviousHighPivot,PreviousHighPivotBar);
? ?? ?? ?? ?If (
? ?? ?? ?? ?findprepivot == True
? ?? ?? ?? ?and LastHighPivot>=(PreviousHighPivot+ HighDifference_min*TRange)