Browse code

column_order can be turned off in oncoprint

jokergoo authored on 29/10/2015 11:00:29
Showing 1 changed files

... ...
@@ -14,7 +14,7 @@
14 14
 # -row_order order of genes. By default it is sorted by frequency of alterations decreasingly.
15 15
 #                            Set it to ``NULL`` if you don't want to set the order
16 16
 # -column_order order of samples. By default the order is calculated by the 'memo sort' method which can visualize
17
-#                                 the mutual exclusivity across genes.
17
+#                                 the mutual exclusivity across genes. Set it to ``NULL`` if you don't want to set the order
18 18
 # -show_column_names whether show column names
19 19
 # -pct_gp graphic paramters for percent row annotation
20 20
 # -axis_gp graphic paramters for axes
... ...
@@ -133,6 +133,7 @@ oncoPrint = function(mat, get_type = function(x) x,
133 133
 
134 134
 	count_matrix = apply(arr, c(1, 2), sum)
135 135
 	if(is.null(row_order)) row_order = seq_len(nrow(count_matrix))
136
+	if(is.null(column_order)) column_order = seq_len(ncol(count_matrix))
136 137
 	row_order = row_order
137 138
 	if(is.character(column_order)) {
138 139
 		column_order = structure(seq_len(dim(arr)[2]), names = dimnames(arr)[[2]])[column_order]