Why the type is wrong?

{
TCanvas *c1 = new TCanvas(“c1”, “c1”,10,10,600,600);
c1->SetGridx();
c1->SetGridy();
gStyle->SetOptStat(“0000”);

TH2F *h2 = new TH2F(“h2”,"",4,0,2,4,0,2);
h2->Draw();
h2->GetXaxis()->SetNdivisions(4);
//h2->GetXaxis()->SetTitle(“t”);
h2->GetXaxis()->CenterTitle(true);

h2->GetYaxis()->SetNdivisions(4);
h2->GetYaxis()->SetTitle(“j_{s}(#Omega,t)”);
h2->GetYaxis()->CenterTitle(true);

FILE *fp=fopen("/home/Administrator/out/data.prn",“r”);
TFile *f=new TFile(“data.root”,“RECREATE”);
TTree *t=new TTree(“T”,“data from ascii file”);
Float_t x[200][1401];
t.Branch(“x”,x,“x[200][1401]/F”);

Int_t r,c;
for(r=0;r<200;r++)
{
for(c=0;c<1401;c++)
{
fscanf(fp,"%f",&x[r][c]);
//printf("%.3f ",x[r][c]);
}
//printf(“r=%03d c=%04d\n”,r,c);
t->Fill();
}

for(c=1350;c<1401;c++)
{
printf("%d\n",c);
h2->Draw();
t->Draw(Form(“x[][%d][][0]”,c),"",“same”);
}

c1->Modified();
}

i run this programm,but all result is:
Error: Incorrect assignment to c, wrong type ‘int’ t.c:47:

why?
please tell me how to change it
Thanks!

line 22 t.Branch should be t->Branch

Hi,

I see nothing _obviously wrong in your code snippet (note that I read is less than 47 lines?). Could you provide a complete example reproducing the problem?
Alternatively you could make this macro a named macro (by adding the necessary #include, and having one function) and then compile the code via ACLiC.

Cheers,
Philippe

[quote]Hi,

I see nothing _obviously wrong in your code snippet (note that I read is less than 47 lines?). Could you provide a complete example reproducing the problem?
Alternatively you could make this macro a named macro (by adding the necessary #include, and having one function) and then compile the code via ACLiC.

Cheers,
Philippe[/quote]
He has t->Fill() inside a loop. I’m not sure about t->Fill() semantics, but this expression should be outside loop. IMHO when in a loop it breaks some internal structures of CINT due to some memory damage.

And yes, he has t.Branch instead of t->Branch