股票公式平台 股票公式 股票软件 手机炒股软件 登录 注册
公式平台网
未来函数检测
首 页 精品公式 通达信公式 大智慧公式 同花顺公式 通达信股票池 大智慧股票池 益盟公式 文华公式 博易大师公式 通达信软件 更多
当前位置:公式平台网金字塔公式 → 正文

金字塔对应平仓示例

发布时间:2022/9/14 15:30:04  浏览次数:
金字塔对应平仓示例

VARIABLE:aa=0;
VARIABLE:bb=0;
if holding=0 then aa:=0;
if holding=0 then bb:=0;

h20:ref(hhv(h,20),1);
l20:ref(llv(l,20),1);
ma2:ma(c,30);

A:=cross(c,h20);
A1:=cross(l20,c);
B:=cross(c,ma2);
B1:=cross(ma2,c);

if aa=1 and holding>0 and A1  then sell(1,holding,limitr,c);
if bb=1 and holding>0 and B1  then sell(1,holding,limitr,c);

if A and holding=0 then
begin
buy(1,1,limitr,c);
IF  A and  holding>0 THEN aa:=1;

end
if B and holding=0 then
begin
buy(1,1,limitr,c);
IF  B and  holding>0 THEN bb:=1;

end


增值电信业务经营ICP许可证:合字B2-20230351  粤ICP备2023083431号-1
免责声明:公式平台网是股票软件指标公式分享平台,不开展相关证券业务,平台展示的所有股票资料由网络收集,不保障实时性和真实性,由此引起的投资亏损与本站无关.
Copyright © 2023 gspt.com , All Rights Reserved.