请教:
aax:tholding,linethick0;
bbx:=extgbdata('quanju');
if bbx>0 then buy(barpos=datacount-1,bbx,thisclose);
if bbx<0 then buyshort(barpos=datacount-1,-bbx,thisclose);
if aax>0 then
begin
SELL ( pd ,1,THISCLOSE); //???à
end
if aax<0 then
begin
SELLSHORT( pk ,1,THISCLOSE); //????
end
if islastbar then extgbdataset('quanju',aax);
图表手动开仓,自动平仓,这样执行的结果好像是:手工开空仓后,执行自动交易,但是每到一个周期到了就加倍开空仓?
图表上用实际持仓?还用后台的全局变量?你想实现什么目标要这么做?
图表不能手工开仓,程序平仓。后台可以。仔细研究一下图表“虚拟”持仓的概念。当然,如果你对金字塔精通后也是可以的。
[此贴子已经被作者于2013/11/21 12:18:03编辑过]