00001 /***************************************************************************** 00002 * Project: RooFit * 00003 * Package: RooFitCore * 00004 * @(#)root/roofitcore:$Id: RooAbsMCStudyModule.cxx 24247 2008-06-12 14:54:32Z wouter $ 00005 * Authors: * 00006 * WV, Wouter Verkerke, UC Santa Barbara, verkerke@slac.stanford.edu * 00007 * DK, David Kirkby, UC Irvine, dkirkby@uci.edu * 00008 * * 00009 * Copyright (c) 2000-2005, Regents of the University of California * 00010 * and Stanford University. All rights reserved. * 00011 * * 00012 * Redistribution and use in source and binary forms, * 00013 * with or without modification, are permitted according to the terms * 00014 * listed in LICENSE (http://roofit.sourceforge.net/license.txt) * 00015 *****************************************************************************/ 00016 00017 ////////////////////////////////////////////////////////////////////////////// 00018 // 00019 // BEGIN_HTML 00020 // RooAbsMCStudyModule is a base class for add-on modules to RooMCStudy that 00021 // can perform additional calculations on each generate+fit cycle managed 00022 // by RooMCStudy 00023 // 00024 // This class can insert code to be executed before each generation step, 00025 // between the generation and fitting step and after the fitting step. 00026 // Any summary output variables declared in the RooDataSet exported through 00027 // summaryData() is merged with the 'master' summary dataset in RooMCStudy 00028 // 00029 // Look at RooDLLSignificanceMCStudyModule for an example of an implementation 00030 // END_HTML 00031 // 00032 // 00033 00034 #include "RooFit.h" 00035 #include "RooAbsMCStudyModule.h" 00036 00037 ClassImp(RooAbsMCStudyModule) 00038 ; 00039 00040 00041 //_____________________________________________________________________________ 00042 RooAbsMCStudyModule::RooAbsMCStudyModule(const char* name, const char* title) : TNamed(name,title), _mcs(0) 00043 { 00044 // Constructor 00045 } 00046 00047 00048 //_____________________________________________________________________________ 00049 RooAbsMCStudyModule::RooAbsMCStudyModule(const RooAbsMCStudyModule& other) : TNamed(other), _mcs(other._mcs) 00050 { 00051 // Copy constructor 00052 } 00053 00054 00055 //_____________________________________________________________________________ 00056 Bool_t RooAbsMCStudyModule::doInitializeInstance(RooMCStudy& study) 00057 { 00058 // Store reference to RooMCStudy object that this module relates to and call internal module 00059 // initialization function 00060 _mcs = &study ; 00061 return initializeInstance() ; 00062 } 00063