[BLAST_ANAWARE] init.C compiled

From: Chris Crawford (chris2@lns.mit.edu)
Date: Sun Jan 25 2004 - 00:45:28 EST


hi,
  i made some changes to init.C, so that one can write compiled analysis
scripts. the change is backward compatible, so none of the current
scripts have to change. basically, i turned all of the un-named scripts
into global variables + functions + dictionary, and each script has a
function of the same name so that ".x ..." still works. note that the
small macros "lr.C", "flr.C", ... are not really needed anymore since
you can call init.C as follows:
           bash> root -l init.C("flr") 3990-3999
    or root [1] .x init.C("flr")
  be aware that init.C now has absolute paths in it that you have to
edit if you check out your own copy from cvs. (module exp/analysis/utils).
  to make use of the new style, have your script include "init.C" at the
beginning of the file, and put the call "init("flr");" somewhere near
the beginning of your function. then you can automatically compile your
named macro in root (ACLiC) with a command like ".x my_macro.C+". also,
use chain[0] instead of the ntuple name (ie. lr->Draw(...))
  here is a sample macro:

//my_macro.C
//#define NO_STRINGS // don't define any of the strings/cuts.
#include "path/to/init.C"
void my_macro()
{
  init("flr");
  chain[0]->Draw("atl:ttr-ttl");
}

  finally, there are a few lines in 'init.C' which you can uncomment so
that it loads from Cint dramatically faster. if you use this, just be
aware that you must compile init.C, before any changes in init.C,
strings.C, cuts.C take effect.

  very finally, i found a few mistakes in cuts.C. you may want to check
if you have used any of them in your analysis:
  Eml_ep_cut, deut[0][12], deut[0][11]

  really the last item, TOpt in libBlast.so has a new global gChain,
which you can also use to form an ntuple chain from the command line.
 see me for details.

--chris



This archive was generated by hypermail 2.1.2 : Mon Feb 24 2014 - 14:07:30 EST