[原創(chuàng)]想買(mǎi)wh9實(shí)盤(pán)但是不知道tb的模型能不能在這邊用 [文華財(cái)經(jīng)]
作者:文華財(cái)經(jīng) 來(lái)源:cxh99.com 發(fā)布時(shí)間:2021年09月13日 點(diǎn)擊數(shù):
【收藏到本網(wǎng)的會(huì)員中心】
-
咨詢(xún)內(nèi)容:
?//------------------------------------------------------------------------// 簡(jiǎn)稱(chēng): zhaoxin11// 名稱(chēng): zhaoxin11// 類(lèi)別: 公式應(yīng)用// 類(lèi)型: 用戶(hù)應(yīng)用// 輸出://------------------------------------------------------------------------
Params?Numeric AfStep( 0.02);?Numeric AfLimit( 0.2 ) ;?Numeric Length(50); //均線(xiàn)周期?Numeric Tiao(0); //跳數(shù)?Numeric Lots(1); //倉(cāng)量???Numeric lostPoint(100); // 50個(gè)點(diǎn),止損?Vars?Numeric oParCl( 0 );??Numeric oParOp( 0 );?Numeric oPosition( 0 );??Numeric oTransition( 0 );?NumericSeries sar;??Numeric ma;?NumericSeries isDo;?NumericSeries lastOpen;?// NumericSeries sar;?Numeric minpoint;?NumericSeries myenterPrice;?Numeric zhisunPrice;?Begin
?ma = AverageFC(Close[1],Length);?ParabolicSAR( AfStep, AfLimit, oParCl, oParOp, oPosition, oTransition ) ;
?COMMENTARY("oParCl="+ Text(oParCl));?// COMMENTARY("oParOp"+ Text(oParOp));?// COMMENTARY("oPosition"+ Text(oPosition));?// COMMENTARY("oTransition"+ Text(oTransition));?// COMMENTARY("MarketPosition"+ Text(MarketPosition));??// COMMENTARY("isDo[0]"+ Text(isDo));?// COMMENTARY("isDo[1]"+ Text(isDo[1]));?COMMENTARY("ma="+ Text(ma));?PlotNumeric("oParCl" , oParCl);???minpoint = MinMove*PriceScale;?zhisunPrice = MinMove * PriceScale * lostPoint;??isDo = oParCl - ma - 10 * Tiao;
?If(MarketPosition==1 )??{? // If(isDo[0] > 0 && isDo[1] <= 0){? If(oParCl > H){? ?Sell(Lots, (h+l)/2);? ?SellShort(Lots, (h+l)/2);? ?lastOpen = O;? }? // zhisunPrice? else if(close[1] < lastOpen - zhisunPrice) {? ? sell(LOTS, open);? ?}?}Else If(MarketPosition==-1){? If(oParCl < L){? ?BuyToCover(Lots, (h+l)/2);? ?Buy(Lots, (h+l)/2);? ?lastOpen = O;? // zhisunPrice? }else if (close[1] > lastOpen + zhisunPrice)? ? {? ? BuyToCover(LOTS,o);? ??
? }?}Else If(MarketPosition==0){? If(oParCl < L){? ?Buy(Lots, O);? ?lastOpen = O;? }Else If(oParCl > H){? ?SellShort(Lots, O);? ?lastOpen = O;? }?}??End
是否可以輔助翻譯成文華9.謝謝?
?來(lái)源:程序化99
-
文華技術(shù)人員:
?
Params
?Numeric Length(50); //均線(xiàn)周期
?Numeric Tiao(0); //跳數(shù)
?Numeric Lots(1); //倉(cāng)量?
?
?Numeric lostPoint(100); // 50個(gè)點(diǎn),止損
?
Vars
?Numeric AfStep;
?Numeric AfLimit ;
?Numeric oParCl( 0 );?
?Numeric oParOp( 0 );
?Numeric oPosition( 0 );?
?Numeric oTransition( 0 );
?Numeric ma1;
?NumericSeries isDo;
?NumericSeries lastOpen;?
// NumericSeries sar;
?Numeric minpoint;
?NumericSeries myenterPrice;
?Numeric zhisunPrice;
?Numeric H,L,O,C;
Begin
AfStep=0.02;
AfLimit=0.2;
?ma1 = AverageFC(Close[1],Length);
?COMMENTARY("oParCl="+ Text(oParCl));COMMENTARY("ma="+ Text(ma1));PlotNumeric("oParCl" , oParCl); ?L=LOW; O=OPEN; C=CLOSE; ?H=HIGH; ?minpoint = MinMove*PriceScale; ?zhisunPrice = MinMove * PriceScale * lostPoint; ? ?isDo = oParCl - ma1 - 10 * Tiao;
?If(MarketPosition==1 )? ?{ ? // If(isDo[0] > 0 && isDo[1] <= 0){ ? If(oParCl > H){ ? ?SP(Lots, (h+l)/2); ? ?SPK(Lots, (h+l)/2); ? ?lastOpen = O; ? } ? // zhisunPrice ? else if(close[1] < lastOpen - zhisunPrice) { ? ? SP(LOTS, open); ? ?} ?}Else If(MarketPosition==-1){ ? If(oParCl < L){ ? ?BP(Lots, (h+l)/2); ? ?BPK(Lots, (h+l)/2); ? ?lastOpen = O; ? // zhisunPrice ? }else if (close[1] > lastOpen + zhisunPrice) ? ? { ? ? BP(LOTS,o); ? ??
? } ?}Else If(MarketPosition==0){ ? If(oParCl < L){ ? ?BPK(Lots, O); ? ?lastOpen = O; ? }Else If(oParCl > H){ ? ?SPK(Lots, O); ? ?lastOpen = O; ? } ?} ? ?End
有思路,想編寫(xiě)各種指標(biāo)公式,交易模型,選股公式,還原公式的朋友
可聯(lián)系技術(shù)人員 QQ: 262069696 或微信號(hào):cxh99cxh99 進(jìn)行 有償收費(fèi) 編寫(xiě)!
(怎么收費(fèi),代編流程等詳情請(qǐng)點(diǎn)擊閱讀!)
(注:由于人數(shù)限制,QQ或微信請(qǐng)選擇方便的一個(gè)聯(lián)系我們就行,加好友時(shí)請(qǐng)簡(jiǎn)單備注下您的需求,否則無(wú)法通過(guò)。謝謝您!)
相關(guān)文章
-
沒(méi)有相關(guān)內(nèi)容