Прошу вас, друзья, изменить alert_message в tradingview, чтобы связаться с FMZ.

Автор:q631207207, Создано: 2021-05-16 21:10:12, Обновлено: 2021-05-16 21:11:40

если (tp1Open)strategy.exit(long1, when=strategy.position_size > 0, limit=strategy.position_avg_price * (1 + tp1), qty_percent=tp1Amount, comment= более плоский 1, alert_message= более плоский 30%)strategy.exit(short1, when=strategy.position_size < 0, limit=strategy.position_avg_price * (1 - tp1), qty_percent=tp1Amount, comment=просто 1, alert_message=просто 30%)

если (tp2Open)strategy.exit(long2, when=strategy.position_size > 0, limit=strategy.position_avg_price * (1 + tp2), qty_percent=tp2Amount, comment= более плоский 2, alert_message= более плоский 50%)strategy.exit(short2, when=strategy.position_size < 0, limit=strategy.position_avg_price * (1 - tp2), qty_percent=tp2Amount, comment=пространство 2, alert_message=пространство 50%)

если (tp3Open)
strategy.exit(long3, when=strategy.position_size > 0, limit=strategy.position_avg_price * (1 + tp3), qty_percent=tp3Amount, comment= более плоский 3, alert_message= более плоский 100%)strategy.exit(short3, when=strategy.position_size < 0, limit=strategy.position_avg_price * (1 - tp3), qty_percent=tp3Amount, comment=простое 3, alert_message=простое 100%)

这是我TV的分批止盈策略,请问该怎么搭建机器人对接?社区的那个直连教程 好像并没有针对这个警报的设置和分批止盈

Больше

Изобретатель количественныйКроме того, изобретатели могут напрямую создать pine создать и просто взять политику и посмотреть, может ли она работать.

q631207207Я переместился, но это не помогло, потому что кое-что не работает, и теперь моя проблема заключается в том, как я должен использовать мою стратегию для получения FMZ-роботов, которые в сообществе, похоже, не разделены.

Изобретатель количественный`` tp1Open = input.bool ((правда, "TP1", group = "Take Profits") tp1 = input.float ((2.0, "TP Level (%) ", step = 0.1, group = "Take Profits") / 100 tp1Amount = input.int ((30, "Amount (%) ", step = 1, group = "Take Profits") tp2Open = input.bool ((правда, "TP2", group = "Take Profits") tp2 = input.float ((2.5, "TP Level (%) ", step = 0.1, group = "Take Profits") / 100 tp2Amount = input.int ((71, "Amount (%) ", step = 1, group = "Take Profits") tp3Open = input.bool ((правда, "TP3", group = "Take Profits") tp3 = input.float ((3.0, "TP Level (%) ", step = 0.1, group = "Take Profits") / 100 tp3Amount = input.int ((100, "Amount (%) ", step = 1, group = "Take Profits") st5=input.float ((1.3, "стоп-лосс", step = 0.1, group = "Take Profits") / 100 alertfg = вход (правда) КА: Да. КА: Да. КА: Да. longCondition = alertfg и close>close[1] if (longCondition) strategy.entry (("long", strategy.long, comment='делать больше', alert_message="делать больше") longsl=alertfg и closeclose[1] strategy.close ("short", when=high > strategy.position_avg_price * (1 + st5) or shortsl,comment='пустой убыток', alert_message="пустой убыток") // Логика выживания if tp1Open strategy.exit ("long1", when=strategy.position_size > 0, limit=strategy.position_avg_price * (1 + tp1), qty_percent=tp1Amount, comment='плохое 1', alert_message="плохое 30%") strategy.exit ("short1", when=strategy.position_size < 0, limit=strategy.position_avg_price * (1 - tp1), qty_percent=tp1Amount, comment='пространственный1', alert_message="пространственный30%") if tp2Open strategy.exit ("long2", when=strategy.position_size > 0, limit=strategy.position_avg_price * (1 + tp2), qty_percent=tp2Amount, comment='плохое 2', alert_message="плохое 50%") strategy.exit ("short2", when=strategy.position_size < 0, limit=strategy.position_avg_price * (1 - tp2), qty_percent=tp2Amount, comment='пространственный2', alert_message="пространственный50%") if tp3Open strategy.exit ("long3", when=strategy.position_size > 0, limit=strategy.position_avg_price * (1 + tp3), qty_percent=tp3Amount, comment='плохое 3', alert_message="плохое 100%") strategy.exit ("short3", when=strategy.position_size < 0, limit=strategy.position_avg_price * (1 - tp3), qty_percent=tp3Amount, comment='пространство 3', alert_message="пространство 100%") `` Это должно быть нормально. Ваши последние строки сокращаются и не изменяются для вас.

Изобретатель количественныйalertfg не определено.

q631207207tp1Open = input.bool ((правда, "TP1", group = "Take Profits") tp1 = input.float ((2.0, "TP Level (%) ", step = 0.1, group = "Take Profits") / 100 tp1Amount = input.int ((30, "Amount (%) ", step = 1, group = "Take Profits") tp2Open = input.bool ((правда, "TP2", group = "Take Profits") tp2 = input.float ((2.5, "TP Level (%) ", step = 0.1, group = "Take Profits") / 100 tp2Amount = input.int ((71, "Amount (%) ", step = 1, group = "Take Profits") tp3Open = input.bool ((правда, "TP3", group = "Take Profits") tp3 = input.float ((3.0, "TP Level (%) ", step = 0.1, group = "Take Profits") / 100 tp3Amount = input.int ((100, "Amount (%) ", step = 1, group = "Take Profits") st5=input.float ((1.3, "стоп-лосс", step = 0.1, group = "Take Profits") / 100 К.С.: Да. Да. Да. Да. Да. Да. Да. Да. longCondition = alertfg and close>close[1] (выполнение условий в режиме ожидания) if (longCondition) strategy.entry (("long", strategy.long, comment='делать больше', alert_message="делать больше") Я не знаю. longsl=alertfg и closeclose[1] strategy.close ("short", when=high > strategy.position_avg_price * (1 + st5) or shortsl,comment='пустой убыток', alert_message="пустой убыток") Я не знаю. // Логика выживания if (tp1Open) strategy.exit ("long1", when=strategy.position_size > 0, limit=strategy.position_avg_price * (1 + tp1), qty_percent=tp1Amount, comment='плохое 1', alert_message="плохое 30%") strategy.exit ("short1", when=strategy.position_size < 0, limit=strategy.position_avg_price * (1 - tp1), qty_percent=tp1Amount,comment='пространственный1', alert_message="пространственный30%") if (tp2Open) strategy.exit ("long2", when=strategy.position_size > 0, limit=strategy.position_avg_price * (1 + tp2), qty_percent=tp2Amount, comment='плохо 2', alert_message="плохо 50%") strategy.exit ("short2", when=strategy.position_size < 0, limit=strategy.position_avg_price * (1 - tp2), qty_percent=tp2Amount, comment='пустой план 2', alert_message="пустой план 50%") Я не знаю. if (tp3Open) strategy.exit ("long3", when=strategy.position_size > 0, limit=strategy.position_avg_price * (1 + tp3), qty_percent=tp3Amount, comment='плохое 3', alert_message="плохое 100%") strategy.exit ("short3", when=strategy.position_size < 0, limit=strategy.position_avg_price * (1 - tp3), qty_percent=tp3Amount,comment='пустой план 3', alert_message="пустой план 100%") Это мой препятствие, я не могу просто ездить туда-сюда, я не могу просто ехать туда-сюда.