- UID
- 2
- 积分
- 2874674
- 威望
- 1387366 布
- 龙e币
- 1487308 刀
- 在线时间
- 13156 小时
- 注册时间
- 2009-12-3
- 最后登录
- 2024-11-24
|
[文华源码] 文华在1分钟K线上叠加分时均价黄线源码[文华财经公式]
咨询内容: 在1分钟K线上可否叠加分时均价黄线,,如何叠加,
技术人员:
分时图中的均价黄色线无法直接提取,您可以通过SETTLE函数近似取得。SETTLE计算开盘以来至今用量进行加权计算的价格均值。
源码如下:
- M:=EMA(REF(SETTLE,1),1);
- A:=M-REF(M,1);
- B:=REFX(A,1);
- AB:=IFELSE(SETTLE>=M,1,-1);
- DRAWSL(REFX(AB,1)=1,M,B,1,0,COLORMAGENTA);
- DRAWSL(REFX(AB,1)=-1,M,B,1,0,COLORGREEN);
- www.cxh99.com:C,NODRAW; DRAWLINE(SETTLE<C&&C>O,H,SETTLE<C&&C>O,C,COLORRED);
- DRAWLINE(SETTLE<C&&C>O,L,SETTLE<C&&C>O,O,COLORRED);
- DRAWLINE(SETTLE<C&&C<O,H,SETTLE<C&&C<O,O,COLORRED);
- DRAWLINE(SETTLE<C&&C<O,L,SETTLE<C&&C<O,C,COLORRED);
- DRAWLINE(SETTLE<C&&C=O,L,SETTLE<C&&C=O,C,COLORRED);
- DRAWLINE(SETTLE<C&&C=O,H,SETTLE<C&&C=O,C,COLORRED);
- DRAWLINE(SETTLE>C&&C>O,H,SETTLE>C&&C>O,C,COLORLIGHTGREEN);
- DRAWLINE(SETTLE>C&&C>O,L,SETTLE>C&&C>O,O,COLORLIGHTGREEN);
- DRAWLINE(SETTLE>C&&C<O,H,SETTLE>C&&C<O,O,COLORLIGHTGREEN);
- DRAWLINE(SETTLE>C&&C<O,L,SETTLE>C&&C<O,C,COLORLIGHTGREEN);
- DRAWLINE(SETTLE>C&&C=O,L,SETTLE>C&&C=O,C,COLORLIGHTGREEN);
- DRAWLINE(SETTLE>C&&C=O,H,SETTLE>C&&C=O,C,COLORLIGHTGREEN);
- STICKLINE(SETTLE<=C&&C>=O,C,O,COLORRED,1);
- STICKLINE(SETTLE<C&&C<O,C,O,COLORRED,0);
- STICKLINE(SETTLE>C&&C>=O,C,O,COLORLIGHTGREEN,1);
- STICKLINE(SETTLE>=C&&C<=O,C,O,COLORLIGHTGREEN,0);
复制代码 |
论坛官方微信、群(期货热点、量化探讨、开户与绑定实盘)
|