我在此部分脚本中遇到此错误-“行186:输入'='不匹配,期望'行尾没有行连续'”。我是新手,有人可以帮助/解释这个问题吗?干杯
one_unit = if (highest(lossincrs,lossbars)) = 1
na(yen_conversion) ? na :round((risk_accountrec/(sl_pips*yen_conversion))/lot_unit*pow(10,round))/pow(10,round)
else
na(yen_conversion) ? na :round((risk_account/(sl_pips*yen_conversion))/lot_unit*pow(10,round))/pow(10,round)
答案 0 :(得分:1)
使用:
one_unit = if (highest(lossincrs,lossbars)) == 1
请参阅:
https://www.tradingview.com/pine-script-docs/en/v4/language/Operators.html#comparison-operators