Revision 4f02356bf15d830e972babb33adbbe26e5b07cce authored by Vladislav Kamenev on 16 October 2018, 14:18:36 UTC, committed by GitHub on 16 October 2018, 14:18:36 UTC
2 parent s af9d405 + f96cbfa
Raw File
subsetES.R
#' Subsets es, if rows or columns are not specified, all are retained
#' @param es ExpressionSet object.#'
#' @param columns List of specified columns' indices (optional), indices start from 0#'
#' @param rows List of specified rows' indices (optional), indices start from 0
#' @return new expression set `es`
#'
#'
subsetES <- function(es, columns = c(), rows=c()) {
    rows <- getIndicesVector(rows, nrow(exprs(es)))
    columns <- getIndicesVector(columns, ncol(exprs(es)))

    es <- es[rows, columns]
    assign("es", es, envir = parent.frame())
}
back to top