例如 在K線圖上
if condition1 then begin
plot1(value1,"B");
plot11( CurrentTimeMS,"BT");//?
end;
if condition2 then begin
plot2(value2,"S");
plot12( CurrentTimeMS,"ST");//?
end;
如何正確顯示"B"、"S" 分別出現的時間點?
例如 在K線圖上
if condition1 then begin
plot1(value1,"B");
plot11( CurrentTimeMS,"BT");//?
end;
if condition2 then begin
plot2(value2,"S");
plot12( CurrentTimeMS,"ST");//?
end;
如何正確顯示"B"、"S" 分別出現的時間點?
Hello xqyi,
currenttime 是當下本機的時間,如果使用在指標上的話過去歷史資料上畫出的會是掛上去當下的時間。
只有掛上去以後的新資料會是腳本在該根Bar運算當下的時間。
您可以考慮使用雷達或自動交易腳本回測,不過需注意 currenttime 在歷史資料上其實就相當於 getfield("Time", "1") (1分鐘逐筆洗價的話會是OHLC15秒一個間距)。
1 評論