SF14

您所在的位置:网站首页 bias指标参数改良源码 SF14

SF14

2024-07-11 02:05:42| 来源: 网络整理| 查看: 265

/ This source code is subject to the terms of the Mozilla Public License 2.0 at https://mozilla.org/MPL/2.0/// © LonesomeTheBlue

//@version=4study("Pivot Point SuperTrend", overlay = true)prd = input(defval = 2, title="Pivot Point Period", minval = 1, maxval = 50)Factor=input(defval = 3, title = "ATR Factor", minval = 1, step = 0.1)Pd=input(defval = 10, title = "ATR Period", minval=1)showpivot = input(defval = false, title="Show Pivot Points")showlabel = input(defval = true, title="Show Buy/Sell Labels")showcl = input(defval = false, title="Show PP Center Line")showsr = input(defval = false, title="Show Support/Resistance")float ph = nafloat pl = naph := pivothigh(prd, prd)pl := pivotlow(prd, prd)plotshape(ph and showpivot, text="H",  style=shape.labeldown, color=na, textcolor=color.red, location=location.abovebar, transp=0, offset = -prd)plotshape(pl and showpivot, text="L",  style=shape.labeldown, color=na, textcolor=color.lime, location=location.belowbar, transp=0, offset = -prd)float center = nacenter := center[1]float lastpp = ph ? ph : pl ? pl : naif lastpp    if na(center)        center := lastpp    else        center := (center * 2 + lastpp) / 3Up = center - (Factor * atr(Pd))Dn = center + (Factor * atr(Pd))float TUp = nafloat TDown = naTrend = 0TUp := close[1] > TUp[1] ? max(Up, TUp[1]) : UpTDown := close[1] < TDown[1] ? min(Dn, TDown[1]) : DnTrend := close > TDown[1] ? 1: close < TUp[1]? -1: nz(Trend[1], 1)Trailingsl = Trend == 1 ? TUp : TDownlinecolor = Trend == 1 and nz(Trend[1]) == 1 ? color.lime : Trend == -1 and nz(Trend[1]) == -1 ? color.red : naplot(Trailingsl, color = linecolor ,  linewidth = 2, title = "PP SuperTrend")plot(showcl ? center : na, color = showcl ? center < hl2 ? color.blue : color.red : na, transp = 0)bsignal = Trend == 1 and Trend[1] == -1ssignal = Trend == -1 and Trend[1] == 1plotshape(bsignal and showlabel ? Trailingsl : na, title="Buy", text="Buy", location = location.absolute, style = shape.labelup, size = size.tiny, color = color.lime, textcolor = color.black, transp = 0)plotshape(ssignal and showlabel ? Trailingsl : na, title="Sell", text="Sell", location = location.absolute, style = shape.labeldown, size = size.tiny, color = color.red, textcolor = color.white, transp = 0)float resistance = nafloat support = nasupport := pl ? pl : support[1]resistance := ph ? ph : resistance[1]plot(showsr and support ? support : na, color = showsr and support ? color.lime : na, style = plot.style_circles, offset = -prd)plot(showsr and resistance ? resistance : na, color = showsr and resistance ? color.red : na, style = plot.style_circles, offset = -prd)alertcondition(Trend == 1 and Trend[1] == -1, title='Buy Signal', message='Buy Signal')alertcondition(Trend == -1 and Trend[1] == 1, title='Sell Signal', message='Sell Signal')alertcondition(change(Trend), title='Trend Changed', message='Trend Changed')



【本文地址】

公司简介

联系我们

今日新闻


点击排行

实验室常用的仪器、试剂和
说到实验室常用到的东西,主要就分为仪器、试剂和耗
不用再找了,全球10大实验
01、赛默飞世尔科技(热电)Thermo Fisher Scientif
三代水柜的量产巅峰T-72坦
作者:寞寒最近,西边闹腾挺大,本来小寞以为忙完这
通风柜跟实验室通风系统有
说到通风柜跟实验室通风,不少人都纠结二者到底是不
集消毒杀菌、烘干收纳为一
厨房是家里细菌较多的地方,潮湿的环境、没有完全密
实验室设备之全钢实验台如
全钢实验台是实验室家具中较为重要的家具之一,很多

推荐新闻


图片新闻

实验室药品柜的特性有哪些
实验室药品柜是实验室家具的重要组成部分之一,主要
小学科学实验中有哪些教学
计算机 计算器 一般 打孔器 打气筒 仪器车 显微镜
实验室各种仪器原理动图讲
1.紫外分光光谱UV分析原理:吸收紫外光能量,引起分
高中化学常见仪器及实验装
1、可加热仪器:2、计量仪器:(1)仪器A的名称:量
微生物操作主要设备和器具
今天盘点一下微生物操作主要设备和器具,别嫌我啰嗦
浅谈通风柜使用基本常识
 众所周知,通风柜功能中最主要的就是排气功能。在

专题文章

    CopyRight 2018-2019 实验室设备网 版权所有 win10的实时保护怎么永久关闭