here I set the number of signal (N_sig) to be around 50 000, but in generateAndFit(), the number of events is 0. I am wondering if this “0” here means “setting the default value of the one I input”?
Because if I changed the 0 to be 100 000, then the pull of the N_sig will not in the range around 0. Since I didn’t find the explanation in ROOT classlist, do you have any idea about it?
Passing 0 for the number of event per sample (nEvtSample in RooMCStudy::generateAndFit ) means that the expected number of events ( pdf->expectedEvents(obs)) will be used.
SInce your model is extended this number will fluctuate according to a Poisson distribution around the expected number of events.
If you instead pass a non-zero value the number of events per sample will fluactuate around that new given value