Index: /trunk/Mars/mjoptim/MJOptimizeDisp.cc
===================================================================
--- /trunk/Mars/mjoptim/MJOptimizeDisp.cc	(revision 18042)
+++ /trunk/Mars/mjoptim/MJOptimizeDisp.cc	(revision 18043)
@@ -235,4 +235,5 @@
 
     MFilterList flist;
+    fPreCuts.Add(&filter);
     flist.AddToList(fPreCuts);
     flist.SetName("PreCuts");
@@ -241,4 +242,12 @@
     MContinue cont(&flist);
     tlist.AddToList(&cont);
+
+    MParameterCalc calcx("0", "CountEvents");
+    tlist.AddToList(&calcx);
+
+    // FIXME: Handle fTestTrain<0
+    MContinue contt("TMath::Odd(CountEvents.fNumExecutions)>0.5", "ContTrain");
+    plist.AddToList(&calcx);
+    tlist.AddToList(&contt);
 
     TString r(rule);
@@ -287,6 +296,6 @@
     loop2.SetDisplay(fDisplay);
     loop2.SetParList(&plist);
-    if (!oop2.Eventloop())
-        return;
+    if (!loop2.Eventloop())
+        return kFALSE;
 
     // Store result if requested
