小编Lik*_*wid的帖子

Pinescript:脚本无法翻译自:

我正在尝试在 TradingView Pinescript 中创建多个移动平均线脚本。不幸的是,它不断抛出错误:

脚本无法翻译自:[“EMA”,“SMA”,“WMA”,“HMA”,“LIN”]

我似乎无法弄清楚我的语法是否不正确或者是否还缺少其他内容。

任何人可以提供的任何帮助将不胜感激。

study("SPY Indicators", shorttitle="SPY Ind", overlay=true)
//@version=1
// Version 1.0
// Author: Likwid


// Definitions: Price and Timeframes
src = input(close, title = "Source")
resolution = timeframe.period
price = security(syminfo.tickerid, resolution, src)

// Defintions: Moving Average periods and types
ma1Period = input(defval=8, title="Period", inline="1", group="Moving Averages: Zone 1")
ma1Type = input(defval="EMA", title="Type", type=input.string, options=["EMA","SMA","WMA","HMA","LIN"], tooltip="MA Smoothing", inline="1", group="Moving Averages: Zone 1")

ma2Period = input(defval=21, title="Period", inline="2", group="Moving Averages: Zone 1")
ma2Type = input(defval="EMA", title="Type", …
Run Code Online (Sandbox Code Playgroud)

pine-script

2
推荐指数
1
解决办法
2万
查看次数

标签 统计

pine-script ×1