Changeset 1999


Ignore:
Timestamp:
04/24/03 11:09:17 (21 years ago)
Author:
wittek
Message:
*** empty log message ***
Location:
trunk/MagicSoft/Mars
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Mars/Changelog

    r1998 r1999  
    11                                                 -*-*- END OF LINE -*-*-
     2
     3 2003/04/24: Wolfgang Wittek
     4
     5    * mfilter/MFCT1SelFinal.cc
     6      - small correction in output
     7
     8    * mhistmc/MHMcCT1CollectionArea.cc
     9      - plot all 3 histograms in DrawClone()
     10
     11    * manalysis/MPadSchweizer.[h,cc]
     12      - cleanup as proposed by Thomas
     13      - new member function SetHistograms() to set the pointers to the
     14        histograms to be used in the padding
     15
     16
    217
    318 2003/04/24: Antonio Stamerra
  • trunk/MagicSoft/Mars/manalysis/MPadSchweizer.cc

    r1961 r1999  
    6969#include "TH2.h"
    7070#include "TH3.h"
    71 #include "TProfile.h"
    7271#include "TRandom.h"
    7372#include "TCanvas.h"
     
    9392// Default constructor.
    9493//
    95 MPadSchweizer::MPadSchweizer(const char *name, const char *title,
    96                              TH2D *fHist2, TH3D *fHist3, TH3D *fHist3Diff) :
    97                fRunType(0), fGroup(0)
     94MPadSchweizer::MPadSchweizer(const char *name, const char *title)
    9895{
    9996  fName  = name  ? name  : "MPadSchweizer";
    10097  fTitle = title ? title : "Task for the padding (Schweizer)";
    10198
    102   fHSigmaTheta    = fHist2;
    103   fHSigmaPixTheta = fHist3;
    104   fHDiffPixTheta  = fHist3Diff;
    105 
    106   fHSigmaTheta->SetDirectory(NULL);
    107   fHSigmaPixTheta->SetDirectory(NULL);
    108   fHDiffPixTheta->SetDirectory(NULL);
    109 
    110   Print();
     99  //fHSigmaTheta    = fHist2;
     100  //fHSigmaPixTheta = fHist3;
     101  //fHDiffPixTheta  = fHist3Diff;
     102
     103  //fHSigmaTheta->SetDirectory(NULL);
     104  //fHSigmaPixTheta->SetDirectory(NULL);
     105  //fHDiffPixTheta->SetDirectory(NULL);
     106
     107  //Print();
    111108}
    112109
     
    122119// --------------------------------------------------------------------------
    123120//
     121// Set the references to the histograms to be used in the padding
     122//
     123//
     124void MPadSchweizer::SetHistograms(TH2D *fHist2, TH3D *fHist3, TH3D *fHist3Diff)
     125{
     126  fHSigmaTheta    = fHist2;
     127  fHSigmaPixTheta = fHist3;
     128  fHDiffPixTheta  = fHist3Diff;
     129
     130  fHSigmaTheta->SetDirectory(NULL);
     131  fHSigmaPixTheta->SetDirectory(NULL);
     132  fHDiffPixTheta->SetDirectory(NULL);
     133
     134  Print();
     135}
     136
     137// --------------------------------------------------------------------------
     138//
    124139// Set the option for the padding
    125140//
     141//  There are 2 options for the padding :                                  //
     142//                                                                         //
     143//  1) fPadFlag = 1 :                                                      //
     144//     Generate first a Sigmabar using the 2D-histogram Sigmabar vs. Theta //
     145//     (fHSigmaTheta). Then generate a pedestal sigma for each pixel using //
     146//     the 3D-histogram Theta, pixel no., Sigma^2-Sigmabar^2               //
     147//     (fHDiffPixTheta).                                                   //
     148//                                                                         //
     149//     This is the preferred option as it takes into account the           //
     150//     correlations between the Sigma of a pixel and Sigmabar.             //
     151//                                                                         //
     152//  2) fPadFlag = 2 :                                                      //
     153//     Generate a pedestal sigma for each pixel using the 3D-histogram     //
     154//     Theta, pixel no., Sigma (fHSigmaPixTheta).                          //
     155//                                                                         //
    126156void MPadSchweizer::SetPadFlag(Int_t padflag)
    127157{
  • trunk/MagicSoft/Mars/manalysis/MPadSchweizer.h

    r1996 r1999  
    1414#include "TH2.h"
    1515#include "TH3.h"
    16 #include "TProfile.h"
    1716
    1817
     
    2120class MPedestalCam;
    2221class MMcEvt;
    23 class MPedestalCam;
    2422class MSigmabar;
    2523class MParList;
     
    6361
    6462public:
    65     MPadSchweizer(const char *name, const char *title,
    66                   TH2D *fHist2, TH3D *fHist3, TH3D *fHist3Diff);
     63    MPadSchweizer(const char *name=NULL, const char *title=NULL);
    6764    ~MPadSchweizer();
     65
     66    void SetHistograms(TH2D     *fHist2=NULL, TH3D *fHist3=NULL,
     67                       TH3D *fHist3Diff=NULL);
    6868
    6969    Bool_t PreProcess(MParList *pList);
     
    7272   
    7373    void SetPadFlag(Int_t padflag);
    74     void SetRunType(Int_t runtype) { fRunType =  runtype; }
    75     void SetGroup(Int_t group)     { fGroup   =  group; }
    7674
    7775    ClassDef(MPadSchweizer, 0)    // task for the padding (Schweizer)
  • trunk/MagicSoft/Mars/mfilter/MFCT1SelFinal.cc

    r1982 r1999  
    8383void MFCT1SelFinal::SetCuts(Float_t hadmax, Float_t alphamax, Float_t distmax)
    8484{
    85   fHadronnessMax = hadmax;
     85  fHadronnessMax =   hadmax;
    8686  fAlphaMax      = alphamax;
    87   fDistMax       = distmax;
    88 
    89   *fLog << inf << "MFCT1SelFinal cut values : fHadronnessMax, fAlphaMax = "
    90         << fHadronnessMax << ",  " << fAlphaMax << ",  fDistMax = " << fDistMax
    91 <<  endl;
     87  fDistMax       =  distmax;
     88
     89  *fLog << inf << "MFCT1SelFinal cut values : fHadronnessMax, fAlphaMax, fDistMax = "
     90        << fHadronnessMax << ",  " << fAlphaMax << ",  " << fDistMax <<  endl;
    9291}
    9392
  • trunk/MagicSoft/Mars/mhistmc/MHMcCT1CollectionArea.cc

    r1992 r1999  
    183183TObject *MHMcCT1CollectionArea::DrawClone(Option_t* option) const
    184184{
    185   TCanvas *c = MH::MakeDefCanvas(fHistCol);
     185  TCanvas &c = *MakeDefCanvas("CollArea", "Collection area plots", 600, 600);
     186  c.Divide(2,2);
    186187
    187188  //
     
    190191  gROOT->SetSelectedPad(NULL);
    191192
     193  c.cd(1);
     194  fHistCol->SetDirectory(NULL);
    192195  fHistCol->DrawCopy(option);
    193196
    194   c->Modified();
    195   c->Update();
    196 
    197   return c;
     197  c.cd(2);
     198  fHistSel->SetDirectory(NULL);
     199  fHistSel->DrawCopy(option);
     200
     201  c.cd(3);
     202  fHistAll->SetDirectory(NULL);
     203  fHistAll->DrawCopy(option);
     204
     205
     206  c.Modified();
     207  c.Update();
     208
     209  return &c;
    198210}
    199211
Note: See TracChangeset for help on using the changeset viewer.