A Quick Start of Using cola Package

Author: Zuguang Gu ( z.gu@dkfz.de )

Date: 2019-10-29

Package version: 1.2.0


Assume your matrix is stored in an object called mat, to perform consensus partitioning, you only need to run following code:

# code only for demonstration
mat = adjust_matrix(mat)  # optional
rl = run_all_consensus_partition_methods(mat, mc.cores = ...)
cola_report(rl, output_dir = ..., mc.cores = ...)

In above code, there are three steps:

  1. Adjust the matrix. In this step, rows with too many NAs are removed. Rows with very low variance are removed. NA values are imputed if there are not too many in each row. Outliers are adjusted in each row. This step is optional.
  2. Run consensus partitioning with multiple methods. The default partition methods are hclust, kmeans, skmeans::skmeans, cluster::pam and Mclust::mclust. The default methods to extract top n rows are sd, cv, MAD and ATC.
  3. Generate a detailed HTML report for the complete analysis.

To perform hierarchical partitioning, run following code:

# code only for demonstration
rh = hierarchical_partition(mat, mc.cores = ...)
cola_report(rh, output_dir = ..., mc.cores = ...)

For the hierarchical partition, you can only select one partition method and one top-value method. The default partition method is kmeans and the default top-value method is MAD.

There are examples on real datasets for cola analysis that can be found at https://jokergoo.github.io/cola_examples/.