I looked at the TGraph documentation it doesn’t seems like there is an option that would do it. But it doesn’t make sense to me that this can’t be done easily.
TGraphErrors *gr1 = new TGraphErrors(data_file, “%lg %lg %lg”);
gr1->Draw(“ALP”);
gr1->Fit(“pol0”);
Since the fit parameter doesn’t really show the slope, Is there a way in root to extract the slope easily?
Thanks in advance.