- UID
- 2
- 积分
- 2874604
- 威望
- 1387331 布
- 龙e币
- 1487273 刀
- 在线时间
- 13155 小时
- 注册时间
- 2009-12-3
- 最后登录
- 2024-11-24
|
【AB_NextColor】
程式码:- inputs:
- MinuteInterval( numericsimple ) ;
- variables:
- var0( 0 ),
- var1( 0 ),
- var2( 0 ),
- var3( 0 ),
- var4( RGBToLegacyColor( GetBackGroundColor ) ) ;
- condition1 = BarType = 1
- and MinuteInterval >= BarInterval
- and ( MinuteInterval <= BarInterval of Data1 or BarType of Data1 = 2 ) ;
-
- if condition1 then
- begin
- var1 = MinutesIntoWeek( DayOfWeek( Date ), Time ) ;
- var0 = BarStatus( 1 ) ;
- condition1 = ( CurrentBar of Data1 = 1 and var0 = 2 ) or var0[1] = 2;
- if condition1 then
- begin
- var3 = 1 ;
- var2 = var1 - BarInterval ;
- end ;
- if var1 > var2 + MinuteInterval then
- begin
- var3 = var3 + 1 ;
- if var3 > 16 then
- var3 = 1 ;
- var2 = var1 - BarInterval ;
- end ;
- if var3 = var4 then
- if var3 = 16 then
- var3 = 1
- else
- var3 = var3 + 1 ;
- end
- else
- var3 = var4 ;
- AB_NextColor = LegacyColorToRGB( var3 ) ;
复制代码 |
论坛官方微信、群(期货热点、量化探讨、开户与绑定实盘)
|