Helper macros

setf (int Mode, int Flag)

Macro that sets a Flag or flag combination in the variable Mode. For instance, setf(TradeMode,TR_PHANTOM) sets the TR_PHANTOM flag for the TradeMode variable.

resf (int Mode, int Flag)

Macro that resets a Flag or flag combination in the variable Mode.

isf (int Mode, int Flag): int

Macro that evaluates to nonzero when the a Flag in the Mode variable is set.  For instance, if(isf(TrainMode,PEAK)) ... checks if the PEAK flag is set in the TrainMode variable.

swap (var a, var b)

Macro that sets a to b and b to a.

Remarks

Example:

function run()
{
  setf(TrainMode,PEAK);
  setf(Detrend,SHUFFLE); 
  ...
}

See also:

set, PlotMode, TrainMode, TradeMode ► latest version online