# Can we shift histogram for several channels?

**URL:** <https://root-forum.cern.ch/t/can-we-shift-histogram-for-several-channels/12050>\
**Category:** ROOT\
**Created:** [March 11, 2011, 3:43pm UTC](https://root-forum.cern.ch/t/can-we-shift-histogram-for-several-channels/12050 "2011-03-11T15:43:24Z")\
**Posts on this page:** 1\
**Showing post:** 1

<div class="post-metadata">

**Author:** ![draudy](https://root-forum.cern.ch/letter_avatar_proxy/v4/letter/d/dbc845/32.png) [@draudy](https://root-forum.cern.ch/u/draudy)\
**Post date:** [March 11, 2011, 3:43pm UTC](https://root-forum.cern.ch/t/can-we-shift-histogram-for-several-channels/12050/1 "2011-03-11T15:43:24Z")

</div>

Good day, everyone here!  
Can anyone give me some informations about these two questions:  
1)If I already have a histogram, can I shift this histogram for several channels in the X axis?  
For example, when I want to calibrate the energy spectrum, E=a\*chn+b, where “a” & “b” is the constants, “chn” is the original x axis, “E” is the new x axis. How can I realize that?

2)During my data analysis, I found that sometimes the cut sequence will affect the result. For instance,  
A. h1-\>Draw(“fast:slow\>\>hist1”,cut2 && cut1 );  
B. h1-\>Draw(“fast:slow\>\>hist2”,cut1 && cut2 );  
" h1" is the tree name, “fast” & “slow” are the branch name, “hist1” &“hist2” are histogram, cut1 & cut2 are cut name.

The events statistic of these two sentences are different! It should be the same! Why the result is different?

Thanks a lot!

My email adress: [draudy.won@gmail.com](mailto:draudy.won@gmail.com)  
MSN: [draudy\_won@hotmail.com](mailto:draudy_won@hotmail.com)

---

_[View the full topic](https://root-forum.cern.ch/t/can-we-shift-histogram-for-several-channels/12050)._
