If no signals are useful, instead of emitting an error message, Zorro should generate a rules .c file with EURUSD_L and EURUSD_S which always return a constant less than 0, meaning no trade is ever advised. I don't understand the need for an error message here. The advise functions already have an approach for handling useless inputs -- they discard them, and the user can open the resulting .c file and see that some inputs played no role. Why should something special happen if all the inputs are useless instead of just some?

A potentially larger question here is why does the lite-C compiler reject this line of code? (mentioned earlier)
Code:
if(+0.04*sig[1] > 0.50)


Is this not allowed in the lite-C grammar? It's valid C. There is no specific lite-C grammar, (http://www.opserver.de/ubb7/ubbthreads.php?ubb=showflat&Number=417318)

For this reason I think I have uncovered a lite-C compiler bug.

Here's another example.
Code:
function run() {
  NumYears = 1;
  AssetList = "AssetsUS.dta";
  LookBack = 900;
  BarPeriod = 1;
  set(RULES+TESTNOW);
  if (Train) {
    set(HEDGING);
    reset(NFA);
    ExitTime = 20;
    NumWFOCycles = 5;
  } else {
    reset(HEDGING);
    set(NFA);
    Stop = 25*PIP;
    TakeProfit = 25*PIP;
  }

  var v00 = CDLMatHold(15);
  var v01 = CDLTristar();
  var v02 = CDLHangingMan();
  var v03 = genSine(109);
  var v04 = AroonOsc(30);
  var v05 = priceLow(0);
  var v06 = CDL3BlackCrows();

  if(adviseLong(PERCEPTRON, 0, v00, v01, v02, v03, v04, v05, v06) > 0) {
    enterLong();
  }
  if(adviseShort() > 0) {
    enterShort();
  }
}


This produces a rules file a_EURUSD.c like
Code:
// Prediction rules generated by Zorro

int EURUSD_L(float* sig)
{
  if(+58.32*sig[3]-91.04*sig[4]-65.42*sig[5] > 44.50)
    return 45;
  else
    return -45;
}

int EURUSD_S(float* sig)
{
  if(+186.00*sig[3]+84.33*sig[4]-115.11*sig[5] > 155.50)
    return 49;
  else
    return -49;
}

// Prediction accuracy: 47%


which Zorro chokes on for syntax error
Code:
Error in 'line 5: 
syntax error
<   if(+58.32*sig[3]-91.04*sig[4]-65.42*sig[5] > 44.50) >


.... but why? This line is fine. If I take out the + signs at the beginning, Zorro can Test the strategy.

lite-c compiler bug laugh