标签:... ble div sage lap cin apply add post
例如有X1,X2,..,Xn个变量,我需要对每一个变量进行频次统计,如果一个一个求解的话非常麻烦,如table(X1), table(X2), ... ,table(Xn)。有没有简单的语句一次性求解?谢谢
假定你X1,X2,...Xn都是一个data frame(df)中的列的话,那么: lapply(df, table) |
标签:... ble div sage lap cin apply add post
原文地址:http://www.cnblogs.com/awishfullyway/p/6633707.html