使用变量 i 在 pine 脚本中获取语法错误

问题描述 投票:0回答:1
percentage_changes[i] = ((open_price_at_end_date - open_price_after_start_date) / open_price_after_start_date) * 100

=
符号导致错误 - 有人可以提供此问题的解决方案吗?我需要比较相同日期的粘贴数据

error-handling pine-script
1个回答
0
投票
percentage_changes[i] = ((open_price_at_end_date - open_price_after_start_date) / open_price_after_start_date) * 100

pinescript
语法无效。

如果要设置数组中元素的值,应该使用

array.set()
。如果你想访问数组中元素的值,你应该使用
array.get()

© www.soinside.com 2019 - 2024. All rights reserved.