Changeset 12923


Ignore:
Timestamp:
02/22/12 19:04:49 (13 years ago)
Author:
tbretz
Message:
Added the possibility to set min and max; increased version number accordingly
Location:
trunk/Mars/mhvstime
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Mars/mhvstime/MHPixVsTime.cc

    r12880 r12923  
    4040//    YOU HAVE TWO SEMICOLON!)
    4141//
     42//
     43// Class Version 2:
     44// ----------------
     45//  + fMaximum
     46//  + fMinumum
     47//
    4248/////////////////////////////////////////////////////////////////////////////
    4349#include "MHPixVsTime.h"
     
    6975//
    7076MHPixVsTime::MHPixVsTime(Int_t idx, const char *name, const char *title)
    71     : fIndex(idx), fEvt(NULL), fType(0), fTypeErr(-1)
     77    : fIndex(idx), fEvt(NULL), fType(0), fTypeErr(-1), fMinimum(-1111), fMaximum(-1111)
    7278{
    7379    //
     
    234240    }
    235241
     242    if (fMinimum!=-1111)
     243        fGraph->SetMinimum(fMinimum);
     244    if (fMaximum!=-1111)
     245        fGraph->SetMaximum(fMaximum);
     246
    236247    TString str(opt);
    237248    if (!str.Contains("A"))
  • trunk/Mars/mhvstime/MHPixVsTime.h

    r12880 r12923  
    3838    Int_t fTypeErr;
    3939
     40    Double_t fMinimum;      // User defined minimum
     41    Double_t fMaximum;      // User defined maximum
     42
    4043    Bool_t SetupFill(const MParList *pList);
    4144    Int_t  Fill(const MParContainer *par, const Stat_t w=1);
     
    4952    void SetType(Int_t type, Int_t e=-1) { fType = type; fTypeErr=e; }
    5053
     54    void SetMinimum(Double_t min=-1111) { fMinimum = min; }
     55    void SetMaximum(Double_t max=-1111) { fMaximum = max; }
     56
    5157    void SetName(const char *name);
    5258    void SetTitle(const char *title);
     
    5763    void Draw(Option_t *o=NULL);
    5864
    59     ClassDef(MHPixVsTime, 1) // Histogram to sum camera events
     65    ClassDef(MHPixVsTime, 2) // Histogram to sum camera events
    6066};
    6167
Note: See TracChangeset for help on using the changeset viewer.