- UID
- 2
- 积分
- 2892817
- 威望
- 1396440 布
- 龙e币
- 1496377 刀
- 在线时间
- 13326 小时
- 注册时间
- 2009-12-3
- 最后登录
- 2024-12-26
|
【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 ) ;
复制代码 |
论坛官方微信、群(期货热点、量化探讨、开户与绑定实盘)
|