- #1
ChrisVer
Gold Member
- 3,378
- 464
I am trying to clarify what someone means by the words : normalize, reweight. So I'll write what I think they do in practice:
1. Normalization: takes a histogram and scales it by a constant value. The shape of the histogram is not changing, but how the y-axis looks does.
2. Reweight : here I get confused. I have seen reweighting applied as a scaling factor to a histogram as well as an argument in the TH1::Fill method. The first obviously doens't change the shape of the histogram but its normalization (and works if the weights are all equal), while the second seems to change the same (because in a histogram of [itex]h(x)[/itex] per [itex]x_i[/itex] goes to [itex]w_i x_i[/itex], right? or does it go to [itex]x_i/ w_i[/itex]? I am also not sure if the sum of weights is being automatically applies: [itex] \frac{w_i x_i}{\sum w_i}[/itex]?
The thing is that I came across a histogram H with x-values ranging from 0-500 and events ranging all over it. I also had weights that were [itex]\sim 10^{-6}[/itex]...what confuses me is after reweighting the resulting histogram H' didn't have its values all taken down to 0 ( an event at 500 for example would have to be brought down to 500 e-6 = 5e-4 etc...) but rather sent up (to around 1000).
1. Normalization: takes a histogram and scales it by a constant value. The shape of the histogram is not changing, but how the y-axis looks does.
2. Reweight : here I get confused. I have seen reweighting applied as a scaling factor to a histogram as well as an argument in the TH1::Fill method. The first obviously doens't change the shape of the histogram but its normalization (and works if the weights are all equal), while the second seems to change the same (because in a histogram of [itex]h(x)[/itex] per [itex]x_i[/itex] goes to [itex]w_i x_i[/itex], right? or does it go to [itex]x_i/ w_i[/itex]? I am also not sure if the sum of weights is being automatically applies: [itex] \frac{w_i x_i}{\sum w_i}[/itex]?
The thing is that I came across a histogram H with x-values ranging from 0-500 and events ranging all over it. I also had weights that were [itex]\sim 10^{-6}[/itex]...what confuses me is after reweighting the resulting histogram H' didn't have its values all taken down to 0 ( an event at 500 for example would have to be brought down to 500 e-6 = 5e-4 etc...) but rather sent up (to around 1000).