void treegen() { const unsigned nPts = 23735; std::ifstream in("3Dtest_large.txt"); if(!in) { std::cout<<"Can not open 3Dtest_large.txt\n"; return; } TFile *f = new TFile("tree.root","recreate"); TTree *t1 = new TTree("t1","a simple Tree with simple variables"); double x = 0., y = 0., z = 0.; double v4 = 1.; t1->Branch("x",&x,"x/D"); t1->Branch("y",&y,"y/D"); t1->Branch("z",&z,"z/D"); t1->Branch("v4",&v4,"v4/D"); t1->Branch("dummy",&z,"dummy/D"); for (unsigned i = 0; i < nPts; ++i) { in>>x>>y>>z; x = TMath::Log(x); y = TMath::Log(y); z = TMath::Log(z); t1->Fill(); } t1->Draw("z:x:y:v4:dummy", "", "gl5d"); }