I’m following the tutorial and have this, which works (I’m compiling it, and then running it – no interactivity):
TCanvas c("c", title.c_str(), 0, 0, width, height);
TF1 f1("f1","sin(x)", -5, 5);
f1.SetTitle(title.c_str());
f1.Draw();
c.Print("plot/all.pdf");
Now, instead of passing an expression like “sin(x)” I want to pass two vectors declared as
vector <double> x, y;
. How do I do that?
I’m sorry, I’m new to ROOT and couldn’t find a solution in the tutorial/documentation.
Best regards
Jérôme
ROOT Version: 6.26/06
Platform: Ubuntu 18.04
Compiler: g++ (Ubuntu 7.5.0-3ubuntu1~18.04) 7.5.0