view add_col_header.xml @ 2:ff2acdb98a74 draft default tip

Uploaded
author estrain
date Tue, 30 Oct 2018 16:52:31 -0400
parents 6af9cdb15e59
children
line wrap: on
line source

<tool id="add_column_headers" name="Add Header" version="0.1.3">
    <description>Add header row with column names to tabular data</description>
    <requirements>
    </requirements>
    <command detect_errors="exit_code"><![CDATA[

      echo $header | sed s/\,/\\t/g  > new_header.txt;
      cat new_header.txt $datatable > output.tab

    ]]></command>
    <inputs>
      <param name="header" type="text" label="List of Column headers (comma delimited, e.g. C1,C2,...)"/>
      <param name="datatable" type="data" format="tabular" label="Data File (tab-delimted)"/>
    </inputs>
    <outputs>
      <data format="tabular" name="Data Table" label="${tool.name} on ${on_string}" from_work_dir="*.tab"/>
    </outputs>

    <help><![CDATA[
    Insert a list of column headers (comma-delimited) as the first row of a data table.  
    ]]></help>
     <citations>
    </citations>
</tool>