Hello, I’m new to Root. My question is if it is possible to fit some points with error bars using the inverse of a user-defined function. Here is the code:

```
const Int_t n1 = 15;
Float_t x1[] = {0.51, 0.54, 0.56, 0.58, 0.57, 0.64, 0.66, 0.7, 0.75, 0.8, 0.83, 0.92, 0.95, 0.98, 0.99};
Float_t y1[] = {0.11, 0.2, 0.31, 0.47, 0.75, 3.4, 4.6, 10, 15, 30, 50, 150, 210, 250, 275};
Float_t ex1[] = {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0};
Float_t ey1[] = {0.0029, 0.0029, 0.0029, 0.0029, 0.0289, 0.0289, 0.0289, 2.8868, 2.8868, 2.8868, 2.8868, 2.8868, 2.8868, 2.8868, 2.8868};
TGraphErrors *gr1 = new TGraphErrors(n1,x1,y1,ex1,ey1);
gr1->Draw("ap");
TF1 *f = new TF1("f", "TMath::Log(x/[0])+[1]*x",.45,1.05);
```

The point is if I necessarily have to change the x with the y of the points in order to use directly the “f” function or is there a method for doing that without swapping the points’ coordinates?

Thanks in advance

*ROOT Version:* 5.23/36

*Platform:* Windows 10

*Compiler:* CINT/ROOT C/C++ Intepreter version 5.18.00