Please read tips for efficient and successful posting and posting code
ROOT Version: 6.22/00
Platform: Ubuntu WSL2
Compiler: gedit, nano.
Hello, I’m new to ROOT. I’m trying to change the title, xlabel and ylabel of my plot. My data is loaded from a .root file, see below.
#include "TFile.h"
#include "TTree.h"
#include "TCanvas.h"
#include "TH1F.h"
#include <iostream>
using namespace std;
void kinetic_energy_vs_position_z(){
TFile * f = new TFile("Myfile.root");
TTree *T = (TTree *) f->Get("output_DATA");
T -> Draw("kinetic_energy" );
}
How do I change the title of my plot and also the x and y label?
Is it possible to make my graph “smoother” ?
Thanks