本页源码来自 TradingView 公开发布的开源脚本,版权归原作者所有, 请遵循其原始许可(Pine 脚本常见 CC BY-NC-SA / MPL-2.0 / MIT)。 本项目仅用于研究检索与许可范围内的移植。
// This source code is subject to the terms of the Mozilla Public License 2.0 at https://mozilla.org/MPL/2.0/
// © dgtrd
//@version=4
study(title="Momentum Acceleration by DGT", shorttitle="SpeedyGonzales by DGT", overlay=true)
t=input(13, title="Length")
p=input(233, "Plotting Length")
s=close
v=sma((s-s[t])/t,3)
a=(v-v[t])/t
c=v-a
plotarrow(c, colorup=color.aqua, colordown=color.orange, transp=85, show_last = p)