# One D Hist

**URL:** <https://root-forum.cern.ch/t/one-d-hist/52191>\
**Category:** Newbie\
**Created:** [November 2, 2022, 12:01am UTC](https://root-forum.cern.ch/t/one-d-hist/52191 "2022-11-02T00:01:18Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Sadhana\_Verma](https://root-forum.cern.ch/user_avatar/root-forum.cern.ch/sadhana_verma/32/29940_2.png) [@Sadhana\_Verma](https://root-forum.cern.ch/u/Sadhana_Verma)\
**Post date:** [November 2, 2022, 12:01am UTC](https://root-forum.cern.ch/t/one-d-hist/52191/1 "2022-11-02T00:01:18Z")

</div>

Hi all !

While running a macro for overalying plots, I am facing quite a lot of errors !  
Though IPlease note that I am not facing these errors while doing the same thing on lxplus and getting a nice plot.

 ![image](https://root-forum.cern.ch/uploads/default/original/3X/b/9/b9645cfccb985c606fdf62adcd5e5f997788b4b3.jpeg)

Please have a look at my macro and the error message and let me know what I should do !  
[oneDHist\_.C](https://root-forum.cern.ch/uploads/short-url/bVFOIVdc616tFdeBN7vBP96dT2k.C) (5.3 KB)

Thanks in advance !

Regards,  
Sadhana

---

<div class="post-metadata">

**Author:** ![couet](https://root-forum.cern.ch/user_avatar/root-forum.cern.ch/couet/32/12037_2.png) [@couet](https://root-forum.cern.ch/u/couet)\
**Post date:** [November 2, 2022, 6:49am UTC](https://root-forum.cern.ch/t/one-d-hist/52191/2 "2022-11-02T06:49:26Z")

</div>

We do not have your data files. Therefore it is not possible to run your macro. Can you provide them of make a macro showing the errors without the need for additional files ?

---

<div class="post-metadata">

**Author:** ![eguiraud](https://root-forum.cern.ch/user_avatar/root-forum.cern.ch/eguiraud/32/32217_2.png) [@eguiraud](https://root-forum.cern.ch/u/eguiraud)\
**Post date:** [November 2, 2022, 8:43am UTC](https://root-forum.cern.ch/t/one-d-hist/52191/3 "2022-11-02T08:43:25Z")

</div>

Hi @Sadhana_Verma ,

as per the error message, some calculations in your code lead to an Inf or NaN (typically the result of a division by zero, the square root of a negative number or similar). The only way to find out is for you to debug your code, using a debugger or inserting print-outs to check what’s going on.

Cheers,  
Enrico
