I’ve only been using root for a little while. I would like to plot multiple functions on one graph, however I can’t seem to get it to work, I am using the below to plot a single function, any help would be much appreciated.
{
gROOT->Reset();
c1 = new TCanvas(“sectheta”,“R”,200,10,700,500);
c1->SetGridx();
c1->SetGridy();
TH1F *hr = c1->DrawFrame(0,0,2000,900);
fun1 = new TF1(“fun1”,“40+0.2794*x”,0,2000);
fun1->Draw();
}
Cheers,
Chris