Triplicates in R -


i have set of 80 samples, 2 variables, each measured triplicate:

sample  var1a    var1b    var1c    var2a    var2b    var2c 1      -169.784 -155.414 -146.555 -175.295 -159.534 -132.511 2      -180.577 -180.792 -178.192 -177.294 -171.809 -166.147 3      -178.605 -184.183 -177.672 -167.321 -168.572 -165.335 

and on. how apply functions mean, sd, se etc. each row var1 , var2? also, dataset contains nas. bothering such basic questions

what expected result when there nas? apply(df[-1], 1, mean) (or whatever function) work, give na result row. if can replace na 0 df[is.na(df)] <- 0 first, , apply function in order results.


Comments

Popular posts from this blog

How has firefox/gecko HTML+CSS rendering changed in version 38? -

javascript - Complex json ng-repeat -

jquery - Cloning of rows and columns from the old table into the new with colSpan and rowSpan -