changeset 1:b8a5139cf5b9 draft

planemo upload commit 5dd4a8814abf4a735409189a4c7cfe3ffd207c62-dirty
author proteore
date Mon, 18 Feb 2019 05:58:08 -0500
parents edbb84a94a36
children 2a04fffda914
files heatmap.xml heatmap_viz.R
diffstat 2 files changed, 5 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/heatmap.xml	Tue Dec 18 09:58:49 2018 -0500
+++ b/heatmap.xml	Mon Feb 18 05:58:08 2019 -0500
@@ -1,4 +1,4 @@
-<tool id="heatmap" name="HeatMap" version="2018.12.12">
+<tool id="heatmap" name="HeatMap" version="2019.02.05">
     <description></description>
     <requirements>
         <requirement type="package" version="4.7.1">r-plotly</requirement>
@@ -12,7 +12,7 @@
             --output="$file.name"  
             --type='$output_type' 
             --cols='$select_data_columns.cols' 
-            --row_names=$rownames 
+            --row_names="$rownames"
             --header='$header' 
             --col_text_angle='$angle_col'
             --dist="$distance"
--- a/heatmap_viz.R	Tue Dec 18 09:58:49 2018 -0500
+++ b/heatmap_viz.R	Mon Feb 18 05:58:08 2019 -0500
@@ -80,7 +80,7 @@
 }
 
 get_cols <-function(input_cols) {
-  input_cols <- gsub("c","",input_cols)
+  input_cols <- gsub("c","",gsub("C","",gsub(" ","",input_cols)))
   if (grepl(":",input_cols)) {
     first_col=unlist(strsplit(input_cols,":"))[1]
     last_col=unlist(strsplit(input_cols,":"))[2]
@@ -102,7 +102,7 @@
 output <- paste(output[1:length(output)-1],collapse=".")
 output <- paste(output,args$type,sep=".")
 cols = get_cols(args$cols)
-rownames_col = as.integer(gsub("c","",args$row_names))
+rownames_col = as.integer(gsub("c","",gsub("C","",gsub(" ","",args$row_names))))
 if (length(cols) <=1 ){
   stop("You need several colums to build a heatmap")
 }
@@ -116,7 +116,7 @@
 uto <- uto[rowSums(is.na(uto)) != ncol(uto), ]  #remove emptylines
 
 if (header) {
-  col_names = names(data)
+  col_names = names(uto)
 } else {
   col_names = cols
 }