I have a txt file which the format is like as following: 123.txt (203 字节)
Now, I want to make the format of datum like:
X-axis -------- “log0.01 log 0.1 log1 …”
Y-axis -------- counts
The only thing I know is to use
" TF2 *f2 = new TF2(“f2”,“xygaus + xygaus(5)”,-4,4,-4,4); "
But the bin is “uniform” not “log”
Would you please help me? Thank you very much for your kind help
Best wishes
ROOT Version: Not Provided Platform: Not Provided Compiler: Not Provided
Can you provide more info that you want to do with points from 123.txt file?
You can check zdemo.C example to see how arbitrary points can be plot on log scale, using TGraph class
TF2 *f2 = new TF2("f2","xygaus + xygaus(5)",-4,4,-4,4);
for (int i = 0; i < f2->GetNpar(); ++i) f2->SetParameter(i, 1.);
f2->Draw("SURF");
gPad->SetLogx();