GetEntries behaviour

pt_w_c1 is a histogram. Why is “get” incremented when Setting the bin content? The number of entries increase by one every time SetBinContent is used.

get = pt_w_c1->GetEntries();
cout << “get before\t” << get ;

pt_w_c1->SetBinContent(ibin,scale34*sig/sig_DY);//this line adds one to entries count

get = pt_w_c1->GetEntries();
cout << “\tget after\t” << get << endl;

Thanks for any help.

This is done on purpose to avoid complaints from users expecting the number of entries non null when SetyBinContent is called.

Rene