[R] labels

About this list Date view Thread view Subject view Author view Attachment view

From: Anna H. Pryor (anna@ptolemy.arc.nasa.gov)
Date: Wed 30 Apr 2003 - 02:04:31 EST


Message-id: <200304290904.31658.anna@ptolemy.arc.nasa.gov>


I don't know how to retain my row labels. I read in a table with row labels,
ie:

Price Floor Area Rooms
52. 111. 830 5
54. 128. 710 5
47.4 101 1000 4
...

but then I need to transform the data

raggedRidzeros <- function(x){
                   
        y = list(ridzeros(x[[1]]))
        for(i in 2:length(x)){
          y = c(y,list(ridzeros(x[[i]])))
        }
        y

}

(where ridzeros is a function that I call to get rid of the zeros in the
vector)
When I do this, I no longer have row labels. Is there any way to insert the
row labels from the original calling function into this function?

Anna

______________________________________________
R-help@stat.math.ethz.ch mailing list
https://www.stat.math.ethz.ch/mailman/listinfo/r-help


About this list Date view Thread view Subject view Author view Attachment view

This archive was generated by hypermail 2.1.3 : Tue 01 Jul 2003 - 09:11:44 EST