Incidentally, the feature becomes really powerful when one uses functions such as addmargins together with prop.table as in
coinf.table <-as.matrix(coinfection) prop.table(coinf.table,1) # to see proportions from each HPV type per study addmargins(coinf.table)# to see totals within study and accross all studies prop.table(addmargins(coinf.table,1),1)# to see proportions for all studies added together On 10/3/07, Farrel Buchinsky <[EMAIL PROTECTED]> wrote: > Genius! Thank you very much. > Yes indeed I should have thought of that. For some reason I have a > mental blank about the use of row.names and instead I repeatedly put > that kind of data as a column in the data frame. Thank you for the > rescue. > -- Farrel Buchinsky GrandCentral Tel: (412) 567-7870 ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.