Ignore:
Timestamp:
07/28/05 16:46:19 (19 years ago)
Author:
Daniela Dorner
Message:
*** empty log message ***
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Mars/datacenter/macros/fillstar.C

    r7226 r7228  
    112112    }
    113113
    114     //spline
    115 //    Float_t psf = (h1->Integral(5, 14) - 0.818)/0.0276;
    116     //df
    117     Float_t psf = (h1->Integral(5, 14) - 0.507)/0.0159;
     114    Float_t numerator = 0;
     115    Float_t denominator = 0;
     116    Float_t summe = 0;
     117
     118    for(Int_t i=5; i<15; i++)
     119    {
     120        numerator   += h1->GetBinContent(i)*h1->GetBinEntries(i);
     121        denominator += h1->GetBinEntries(i);
     122    }
     123
     124    summe = numerator/denominator;
     125
     126    Float_t psf = (summe - 0.04816)/0.001294;
    118127    psf = TMath::Nint(psf*10)/10.;
    119128    TString PSF = Form("%5.1f", psf);
     
    127136    }
    128137
    129     Float_t integral = h2->Integral(5, 14);
    130     //spline
    131 //    Float_t integralmc = -36.06*psf + 11023;
    132     //df
    133     Float_t integralmc = -24.1*psf + 10104.2;
    134     Float_t ratiodatamc = (integral/integralmc)*100;
     138    numerator = 0;
     139    denominator = 0;
     140    summe = 0;
     141
     142    for(Int_t i=5; i<15; i++)
     143    {
     144        numerator   += h2->GetBinContent(i)*h2->GetBinEntries(i);
     145        denominator += h2->GetBinEntries(i);
     146    }
     147
     148    summe = numerator/denominator;
     149
     150    Float_t integralmc = -1.43*psf + 1035;
     151    Float_t ratiodatamc = (summe/integralmc)*100;
    135152    TString ratio = Form("%5.1f", ratiodatamc);
    136153
Note: See TracChangeset for help on using the changeset viewer.