Problem in execution

Dear developers,

I am running a script,apparently it has no issues but it is not compiling. I execute my script and it shows processing but it will stop without giving results. Kindly check this issue.

fake_ratio.cc (7.3 KB)
mor_tqzll_lat_MergedMiniEvents_0.root (1.1 MB)

Thanks
Nab

Hi,

I think we need more information and a minimal reproducer of the problem.
What are you trying to achieve? What is exactly the issue?

Cheers,
D

I want to generate histograms and save in a root file. This macro generates no histogram neither save it in a root file.

I see.
Can you share a minimal reproducer to help you debug the problem?
ROOT can generate histos and write them on a file:

TFile f("a.root","RECREATE");
TH1F h("a","a",64,-2,2);
h.FillRandom("gaus");
h.Write();
f.Close();

Perhaps there is a mistake in your code?

Cheers,
D

I donot fill histograms with random number. I my macro I have a full analysis. I want to store Z_mass, W_trans_mass into a root file. At the beginning this script runs but i donot know what happened to it know. I am doing like you mensioned. I have attached my script, Please see it

I have changed certain things but still the problem remains same. My histograms remains empty.
fake_ratio.cc (7.3 KB)

Hi,

Use ACLiC, it will already give you some errors to fix…

Cheers, Bertrand.

Hi,

I removed all the errors, but again it gives me empty histograms

Then check your conditions, and verify that you really fill them with something… (add printf statements if you don’t know how to debug using gdb…)

I checked all the conditions before. It was a running macro, but I donot know what happened to it

If you have this kid of error:

   if (fabs(m_tmp) < min_m);
   {

instead of

   if (fabs(m_tmp) < min_m)
   {

You should be able to catch them by adding printf statements in your code…

[quote=“nab, post:10, topic:25535”]
It was a running macro, but I donot know what happened to it
[/quote]Well, someone probably modified it the wrong way… :wink:

Hahaha may be :slight_smile:

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.