請問如果 策略執行中
要怎麼寫 額外手動進場之後給策略監控 接下來的進出 並設定停損
if (Position = 0 and filled = 1) then
begin
L_StopPrice = Low - ATR(20);
end
請問上面寫法對嗎
或者有更好的寫法 謝謝
請問如果 策略執行中
要怎麼寫 額外手動進場之後給策略監控 接下來的進出 並設定停損
if (Position = 0 and filled = 1) then
begin
L_StopPrice = Low - ATR(20);
end
請問上面寫法對嗎
或者有更好的寫法 謝謝
手動進場,讓原本的策略進行監控,你需要設定策略部位,選擇「與庫存同步」,並將底下三個核取方塊打勾。策略裡面的程式就按照原本的進場與出場規則即可,不需要另外處理。
了解 謝謝
因為還有寫 註記進場K
還有停損的點為設定
L_BullPrice = Close[1];
L_StopPrice = Low - newstopatr *ATRSTOP;
請問
這樣也是一樣嗎?
不懂你的意思。你原本打算進場及出場的條件各是什麼?另外,請把另一篇重複的貼文刪除。
可能誤發 刪除了~~
我想要在策略 沒有進場時候 ~~主觀上覺得可以進場
進了之後 停損 觸損 保本保利 給程式策略自己做
所以需要偵測 哪時候進場 抓進場的K棒 還有抓進場的價格
//手動多
if (Position[1]= 0 and filled [1]= 0) and(Position= 0 and filled > 0) then
begin
L_BullPrice = Close[1];
L_StopPrice = Low -ATRSTOP;
L_Trail = False;
breakeven = false;
Win_Bar = currentBar;
Win_Price = close;
end ;
不知道這樣偵測手動進場對嗎 或者有其他寫法
進場的K棒可以用以下陳述式判斷:
if position[1]=0 and filled[1]=0 and position>0 and filled>0 then
begin
InBar=currentBar;
end;
filledAvgPrice則是進場價格。
了解 我嘗試看看 謝謝~
if position[1]=0 and filled[1]=0 and position>0 and filled>0 then
position>0 position=0
請問這個判斷手動進場有錯嗎? 或者有其他方式 或者內建函數
因為策略進場 不是用position?
你先搞懂position與filled的差異,以及position的用法吧!
8 評論