What I was proposing doesn't require a lot of programming. Just whenever you call dim(), it does length() if the object is a vector and returns it in the format:
R> a <- 1:12 R> dim(a) [1] 12
One problem is that there is code using is.null(dim(x)) to distinguish vectors from matrices. This code would break.
-thomas
______________________________________________ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html