TCanvas

Dear expert,
I want to put two histos side by side on same canvas,

 C.reset(new TCanvas("C", "PH"));
C.get()->Divide(2,1);
 C.get()->cd(1);

  h1.reset(new TProfile("h1, "PH", 30, -0.5, 29.5));
  mPulseHeightpro.get()->Sumw2();
  mPulseHeightpro.get()->Draw();
   
 C.get()->cd(2);
  h2.reset(new TProfile2D("h2", "PH", 30, -0.5, 29.5, 540, 0, 540));
 h2.get()->Sumw2();
  h2.get()->Draw();

  getObjectsManager()->startPublishing(C.get());


this is local result. and this is what i want.

but on QCG plots are super impose on each other

Hi @namalik ,

Thank you for reporting the issue. This was caused by a bug in JSROOT 6.x which was fixed in JSROOT 7.x.
We have now migrated QCG to the new JSROOT and I confirm I do not see the issue anymore.

In the future, as we host multiple qcg platforms, please provide a link to the object you are trying to plot so that we can quickly identify the environment and replicate the issue. In your scenario, something like: https://qcg-test.cern.ch/?page=objectView&objectName=qc/TRD/MO/DigitTask1/PulseHeight/mPH2Dpro

Have a nice day,
George

1 Like