{ int i; const Int_t nx = 8; char *os_X[nx] = {"8","32","128","512","2048","8192","32768","131072"}; float d_35_0[]= {0.75, 3.30, 0.92, 0.10, 0.08, 1.69, 1.29, 2.37}; float d_35_1[]= {1.01, 3.02, 0.65, 0.37, 0.34, 1.42, 1.02, 2.10}; TCanvas *cb = new TCanvas("cb","cb",600,400); cb->SetGrid(); cb->SetBottomMargin(0.1); cb->SetFillColor(10); cb->SetBorderMode(0); TH1F *h = new TH1F("h","",nx,0,nx); h->SetFillColor(4); h->SetBarWidth(0.4); h->SetBarOffset(0.1); h->SetStats(0); for (i=1;i<=nx;i++) { h->Fill(os_X[i-1], d_35_0[i-1]); h->GetXaxis()->SetBinLabel(i,os_X[i-1]); } h->Draw("b text0"); TH1F *h2 = new TH1F("h2","test",nx,0,nx); h2->SetFillColor(38); h2->SetBarWidth(0.4); h2->SetBarOffset(0.5); h2->SetStats(0); for (i=1;i<=nx;i++) { h2->Fill(os_X[i-1], d_35_1[i-1]); } h2->Draw("b text0 same"); }