<commit_before>#ifndef ALIHFSYSTERR_H
#define ALIHFSYSTERR_H
/* Copyright(c) 1998-2010, ALICE Experiment at CERN, All rights reserved. *
 * See cxx source for full Copyright notice                               */

/* $Id$ */

//***********************************************************
/// \class Class AliRDHFSystErr
/// \brief to handle systematic errors for charm hadrons
/// \author Author: A.Dainese, <EMAIL>
//***********************************************************

#include <TNamed.h>
#include <TString.h>
#include <TH1F.h>
#include "AliLog.h"
#include "TGraphAsymmErrors.h"


class AliHFSystErr : public TNamed
{
 public:

  AliHFSystErr(const Char_t* name="AliHFSystErr", const Char_t* title="");

  virtual ~AliHFSystErr();

  void DrawErrors(TGraphAsymmErrors *grErrFeeddown=0) const;

  Double_t GetNormErr() const {return (fNorm ? fNorm->GetBinContent(0) : 0.);}
  Double_t GetBRErr() const {return (fBR ? fBR->GetBinContent(0) : 0.);}
  Double_t GetCutsEffErr(Double_t pt) const;
  Double_t GetMCPtShapeErr(Double_t pt) const;
  Double_t GetSeleEffErr(Double_t pt) const;
  Double_t GetPartAntipartErr(Double_t pt) const;
  Double_t GetPIDEffErr(Double_t pt) const;
  Double_t GetRawYieldErr(Double_t pt) const;
  Double_t GetTrackingEffErr(Double_t pt) const;
  Double_t GetDataDrivenFDErr(Double_t pt) const;
  Double_t GetRawYieldFDCorr(Double_t pt) const;
  Double_t GetTotalSystErr(Double_t pt,Double_t feeddownErr=0) const;

  void  ResetRawYieldErr(Double_t pt, Double_t val){
    fRawYield->SetBinContent(fRawYield->FindBin(pt),val);
  }
  void  ResetCutEfficErr(Double_t pt, Double_t val){
    fCutsEff->SetBinContent(fCutsEff->FindBin(pt),val);
  }
  void  ResetPIDEfficErr(Double_t pt, Double_t val){
    fPIDEff->SetBinContent(fPIDEff->FindBin(pt),val);
  }
  void  ResetMCPtShapeErr(Double_t pt, Double_t val){
    fMCPtShape->SetBinContent(fMCPtShape->FindBin(pt),val);
  }
  void  ResetTrackEfficErr(Double_t pt, Double_t val){
    fTrackingEff->SetBinContent(fTrackingEff->FindBin(pt),val);
  }
  /// Setting  the run number
  ///  set the two last numbers of the year (is 10 for 2010)
  void SetRunNumber(Int_t number) {
    fRunNumber = number;
    AliInfo(Form(" Settings for run year 20%2d",fRunNumber));
  }
  Int_t GetRunNumber() const { return fRunNumber; }
  /// Setting the collision type
  ///  0 is pp, 1 is PbPb, 2 is pPb
  void SetCollisionType(Int_t type) {
    fCollisionType = type;
    if (fCollisionType==0) { AliInfo(" Settings for p-p collisions"); }
    else if(fCollisionType==1) { AliInfo(" Settings for Pb-Pb collisions"); }
    else if(fCollisionType==2) { AliInfo(" Settings for p-Pb collisions"); }
  }
  Int_t GetCollisionType() const { return fCollisionType; }<commit_msg>Add method to reset data-driven fraction syst<commit_after>#ifndef ALIHFSYSTERR_H
#define ALIHFSYSTERR_H
/* Copyright(c) 1998-2010, ALICE Experiment at CERN, All rights reserved. *
 * See cxx source for full Copyright notice                               */

/* $Id$ */

//***********************************************************
/// \class Class AliRDHFSystErr
/// \brief to handle systematic errors for charm hadrons
/// \author Author: A.Dainese, <EMAIL>
//***********************************************************

#include <TNamed.h>
#include <TString.h>
#include <TH1F.h>
#include "AliLog.h"
#include "TGraphAsymmErrors.h"


class AliHFSystErr : public TNamed
{
 public:

  AliHFSystErr(const Char_t* name="AliHFSystErr", const Char_t* title="");

  virtual ~AliHFSystErr();

  void DrawErrors(TGraphAsymmErrors *grErrFeeddown=0) const;

  Double_t GetNormErr() const {return (fNorm ? fNorm->GetBinContent(0) : 0.);}
  Double_t GetBRErr() const {return (fBR ? fBR->GetBinContent(0) : 0.);}
  Double_t GetCutsEffErr(Double_t pt) const;
  Double_t GetMCPtShapeErr(Double_t pt) const;
  Double_t GetSeleEffErr(Double_t pt) const;
  Double_t GetPartAntipartErr(Double_t pt) const;
  Double_t GetPIDEffErr(Double_t pt) const;
  Double_t GetRawYieldErr(Double_t pt) const;
  Double_t GetTrackingEffErr(Double_t pt) const;
  Double_t GetDataDrivenFDErr(Double_t pt) const;
  Double_t GetRawYieldFDCorr(Double_t pt) const;
  Double_t GetTotalSystErr(Double_t pt,Double_t feeddownErr=0) const;

  void  ResetRawYieldErr(Double_t pt, Double_t val){
    fRawYield->SetBinContent(fRawYield->FindBin(pt),val);
  }
  void  ResetCutEfficErr(Double_t pt, Double_t val){
    fCutsEff->SetBinContent(fCutsEff->FindBin(pt),val);
  }
  void  ResetPIDEfficErr(Double_t pt, Double_t val){
    fPIDEff->SetBinContent(fPIDEff->FindBin(pt),val);
  }
  void  ResetMCPtShapeErr(Double_t pt, Double_t val){
    fMCPtShape->SetBinContent(fMCPtShape->FindBin(pt),val);
  }
  void  ResetTrackEfficErr(Double_t pt, Double_t val){
    fTrackingEff->SetBinContent(fTrackingEff->FindBin(pt),val);
  }
  void  ResetDataDrivenFDErr(Double_t pt, Double_t val){
    if (fDataDrivenFD) {
      fDataDrivenFD->SetBinContent(fDataDrivenFD->FindBin(pt),val);
    }
  }
  /// Setting  the run number
  ///  set the two last numbers of the year (is 10 for 2010)
  void SetRunNumber(Int_t number) {
    fRunNumber = number;
    AliInfo(Form(" Settings for run year 20%2d",fRunNumber));
  }
  Int_t GetRunNumber() const { return fRunNumber; }
  /// Setting the collision type
  ///  0 is pp, 1 is PbPb, 2 is pPb
  void SetCollisionType(Int_t type) {
    fCollisionType = type;
    if (fCollisionType==0) { AliInfo(" Settings for p-p collisions"); }
    else if(fCollisionType==1) { AliInfo(" Settings for Pb-Pb collisions"); }
    else if(fCollisionType==2) { AliInfo(" Settings for p-Pb collisions"); }
  }
  Int_t GetCollisionType() const { return fCollisionType; }
{'fraction_non_alphanumeric': 0.15308641975308643, 'fraction_numerical': 0.010582010582010581, 'mean_word_length': 4.603754940711463, 'pattern_counts': {'":': 0, '<': 11, '<?xml version=': 0, '>': 37, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5193984', 'n_tokens_mistral': 2099, 'n_tokens_neox': 2018, 'n_words': 462}