[R] str and structable error

Petr Pikal petr.pikal at precheza.cz
Mon Nov 28 08:38:07 CET 2005


Hallo

I encountered a behaviour which puzzles me (but 
finally I did get what I wanted).

I used structable and strucplot but I wanted to change 
names of variables in structable object. I tried to subset 
it, use names but to no avail. So I tried str and 
expected to get a structure of an object but:

> sss<-structable(Titanic)
> str(sss)
Error in "[.structable"(x, args[[1]], ) : subscript out of 
bounds

Finally I learned, that I need to change attributes of 
structable object.

Is this error message OK and I did not read 
documentation properly? Or is it normal that str gives 
an error on some objects but I just was not so lucky to 
meet one?.

W2000, R2.2.0, vcd package Built: R 2.2.0; ; 2005-11-
22 14:23:44; windows, 

Best regards.

Petr

Petr Pikal
petr.pikal at precheza.cz




More information about the R-help mailing list