指标: BrainTrend2Sig

 

BrainTrend2Sig:

BrainTrend2Sig是根据趋势方向分配颜色到K线的市场趋势指标。

BrainTrend2Sig

作者: Nikolay Kositsin

 

如何从我的 EA 连接到它?

如果可能,请提供示例代码

 

请告诉我如何配置BrainTrend2Sig,以便通过信使、短信或电话发送通知?

不胜感激

 
这是一个有趣的指标。但我没有看到 "所有变量",只有一个。还有两个是我自己调出来的(从常量中)。
你打算在此基础上为子窗口发布一个非箭头指标吗?
 
Boris Egorov:

如何从我的 EA 连接到它?

如果可能,请提供示例代码

iCustom +CopyBuffer
 

早上好!我正试图在自定义EA中使用该指标。在 mt4 中,它工作得很好,但在 mt5 中,我很难做到这一点:

Hello good morning, I'm trying to use the indicator in a custom EA. In mt4 it works perfectly, but in mt5 I have difficulty doing the same, in mt4 I call the indicator this way and it has worked:


// Chama a função iCustom para obter o valor da seta azul
   redArrowValue = iCustom(Symbol(), Period(), "BT2", 0, 0);

// Chama a função iCustom para obter o valor da seta vermelha
   blueArrowValue = iCustom(Symbol(), Period(), "BT2", 1, 0);





// Condição de venda: Preço acima da linha de cima e sinal de venda no BT2
   if(!HasOpenPositions(Symbol(), MagicNumber) && CheckStartMarket() && currentPrice > upBuffer && redArrowValue == 1 && blueArrowValue > 0 && previousOpen > upBuffer)
     {
      SellOrder(TakeProfit, StopLoss);
      partialCloseActivated = false;
      breakevenActivated = false;
      Alert("Venda efetuada!");
     }

// Condição de compra: Preço abaixo da linha de baixo e sinal de compra no BT2
   if(!HasOpenPositions(Symbol(), MagicNumber) && CheckStartMarket() && currentPrice < dnBuffer && blueArrowValue == 2 && redArrowValue > 0 && previousOpen < dnBuffer)
     {
      BuyOrder(TakeProfit, StopLoss);
      partialCloseActivated = false;
      breakevenActivated = false;
      Alert("Compra efetuada!");
     }
  }


 
记住,每个人都有不同 优势。