請(qǐng)問如何表述連續(xù)10天低于10日均價(jià)
作者:開拓者 TB 來源:cxh99.com 發(fā)布時(shí)間:2022年06月20日
-
咨詢內(nèi)容:
請(qǐng)問如何表述連續(xù)10天低于10日均價(jià)?在文華財(cái)經(jīng)里有函數(shù) Every(close,10)<Ma10,請(qǐng)問開拓者里怎么表述?不勝感激
?
?來源:CXH99.COM
-
TB技術(shù)人員:
使用countif就可以了
- Params
- ? ? ? ?
- Vars
- ? ? ? ? NumericSeries ma10;
- ? ? ? ? Numeric count;
- ? ? ? ? Bool isLow;
- Begin
- ? ? ? ? If(!CallAuctionFilter()) Return;
- ? ? ? ? ma10 = Average(Close,10);
- ? ? ? ? PlotNumeric("ma10",ma10);
- ? ? ? ? isLow = Close < ma10;
- ? ? ? ? If(isLow){
- ? ? ? ? ? ? ? ? PlotString("isLow","L",Low,Red);
- ? ? ? ? }
- ? ? ? ? count = CountIf(isLow,10);
- ? ? ? ? If(count == 10){
- ? ? ? ? ? ? ? ? PlotString("isOk","Y",High,Yellow);
- ? ? ? ? }
- End
復(fù)制代碼?
-
TB客服:
zbzdsk 發(fā)表于 2019-11-16 16:28
使用countif就可以了
謝謝啦,我以前用文華,現(xiàn)在用TB,以后多交流