{ auto c1 = new TCanvas("c1","Signal-to-noise ratio for different absorber thicknesses",200,10,700,500); //Making the canvas c1->GetFrame()->SetBorderSize(12); //Setting a boardersize for the canvas const Int_t n = 6; Double_t x[n] = {0, 0.36, 0.725, 1.155, 1.485, 1.895}; //Defining the vector for the thickness Double_t y[n] = {16.63559463, 12.50050697, 9.120482874, 6.562466825, 5.106270529, 3.679101254}; //Defining a vector the the signal to noise ratio auto gr = new TGraph(n,x,y); //Making a graph that takes in the vectors as parameters gr->SetTitle("Signal-to-noise ratio for different absorber thicknesses; Absorber thickness, x [cm]; Signal-to-noise, I/I_B"); //Setting a main title and titles on the axis gr->GetYaxis()->CenterTitle(true); //Centering the Y-axis gr->GetXaxis()->CenterTitle(true); //Centering the X-axis gr->SetMarkerStyle(8); //Marker is a large scalable dot gr->SetMarkerColor(1); //Marker is black gr->SetMarkerSize(0.8); //Setting the size of the marker gr->SetLineColor(9); //Line is blue gr->SetLineWidth(2); //Setting the width of the line gr->Draw("APL"); //Drawing the graph with axis, markers and lines between the points }