50 double getValue(std::string branch_name);
90 virtual void addVariable(std::string variableName,
double param)=0;
99 std::map<std::string,double*>
tuple_;
Reads flat TTree and allows user to create new variables in the TTree.
void initializeFlatTuple(TTree *tree, std::map< std::string, double * > &tuple_map)
read in the initial flat TTree
void GetEntry(int entry)
get tree entry
void defineMassWindow(double lowMass, double highMass)
Set the mass window within which to read the input ttree.
double getValue(std::string branch_name)
Get the value of a flat tuple variable.
void shiftVariable(std::string variable, double shift)
Apply any corrections to specified variable.
int GetEntries()
return number of entries in tree
void setBranchValue(std::string branch_name, double value)
Set branch value.
TTree * newtree_
temporary ttree used to create and fill new branches
std::vector< std::string > getAllVariables()
Get list of all variables defined in ttree.
void addNewBranch(std::string branch)
Add new branch to ttree.
void copyTTree()
copy the TTree
void printEvent()
Print TTree Event.
virtual void addVariable(std::string variableName, double param)=0
std::map< std::string, double * > tuple_
holds all variables and values
void addVariableToTBranch(const std::string &variableName)
std::map< std::string, TBranch * > new_branches
list of new branches added to ttree
bool variableExists(std::string variable)
Check if a variable exists in the ttree.
double lowMass_
mass window low
double highMass_
mass window high
std::map< std::string, std::function< double()> > variable_shifts_
variable corrections
std::map< std::string, std::function< double()> > functions_
functions that calculate new variables
void Fill()
Fill ttree with new variables included.
std::map< std::string, double * > new_variables_
list of new variables