## Simulate some count data and the features length
datasim = matrix(sample(0:100, 2000, replace = TRUE), ncol = 4)
lengthsim = sample(100:1000, 500)
## RPKM normalization
myrpkm = rpkm(datasim, long = lengthsim, lc = 1, k = 0)
## Upper Quartile normalization, dividing normalized data by the square root of the features length and replacing counts=0 by k=1
myuqua = uqua(datasim, long = lengthsim, lc = 0.5, k = 1)
## TMM normalization with no length correction
mytmm = tmm(datasim, long = 1000, lc = 0, k = 0)
Run the code above in your browser using DataLab