# HG changeset patch # User ethevenot # Date 1470133601 14400 # Node ID ad06aeed02c99f76d21e96b23b019d5857417134 planemo upload for repository https://github.com/workflow4metabolomics/heatmap.git commit 7e599d006e53fefb7e1b923ba8894b4fb19f9cfa-dirty diff -r 000000000000 -r ad06aeed02c9 LICENSE.md --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/LICENSE.md Tue Aug 02 06:26:41 2016 -0400 @@ -0,0 +1,517 @@ + CeCILL FREE SOFTWARE LICENSE AGREEMENT + +Version 2.1 dated 2013-06-21 + + + Notice + +This Agreement is a Free Software license agreement that is the result +of discussions between its authors in order to ensure compliance with +the two main principles guiding its drafting: + + * firstly, compliance with the principles governing the distribution + of Free Software: access to source code, broad rights granted to users, + * secondly, the election of a governing law, French law, with which it + is conformant, both as regards the law of torts and intellectual + property law, and the protection that it offers to both authors and + holders of the economic rights over software. + +The authors of the CeCILL (for Ce[a] C[nrs] I[nria] L[ogiciel] L[ibre]) +license are: + +Commissariat à l'énergie atomique et aux énergies alternatives - CEA, a +public scientific, technical and industrial research establishment, +having its principal place of business at 25 rue Leblanc, immeuble Le +Ponant D, 75015 Paris, France. + +Centre National de la Recherche Scientifique - CNRS, a public scientific +and technological establishment, having its principal place of business +at 3 rue Michel-Ange, 75794 Paris cedex 16, France. + +Institut National de Recherche en Informatique et en Automatique - +Inria, a public scientific and technological establishment, having its +principal place of business at Domaine de Voluceau, Rocquencourt, BP +105, 78153 Le Chesnay cedex, France. + + + Preamble + +The purpose of this Free Software license agreement is to grant users +the right to modify and redistribute the software governed by this +license within the framework of an open source distribution model. + +The exercising of this right is conditional upon certain obligations for +users so as to preserve this status for all subsequent redistributions. + +In consideration of access to the source code and the rights to copy, +modify and redistribute granted by the license, users are provided only +with a limited warranty and the software's author, the holder of the +economic rights, and the successive licensors only have limited liability. + +In this respect, the risks associated with loading, using, modifying +and/or developing or reproducing the software by the user are brought to +the user's attention, given its Free Software status, which may make it +complicated to use, with the result that its use is reserved for +developers and experienced professionals having in-depth computer +knowledge. Users are therefore encouraged to load and test the +suitability of the software as regards their requirements in conditions +enabling the security of their systems and/or data to be ensured and, +more generally, to use and operate it in the same conditions of +security. This Agreement may be freely reproduced and published, +provided it is not altered, and that no provisions are either added or +removed herefrom. + +This Agreement may apply to any or all software for which the holder of +the economic rights decides to submit the use thereof to its provisions. + +Frequently asked questions can be found on the official website of the +CeCILL licenses family (http://www.cecill.info/index.en.html) for any +necessary clarification. + + + Article 1 - DEFINITIONS + +For the purpose of this Agreement, when the following expressions +commence with a capital letter, they shall have the following meaning: + +Agreement: means this license agreement, and its possible subsequent +versions and annexes. + +Software: means the software in its Object Code and/or Source Code form +and, where applicable, its documentation, "as is" when the Licensee +accepts the Agreement. + +Initial Software: means the Software in its Source Code and possibly its +Object Code form and, where applicable, its documentation, "as is" when +it is first distributed under the terms and conditions of the Agreement. + +Modified Software: means the Software modified by at least one +Contribution. + +Source Code: means all the Software's instructions and program lines to +which access is required so as to modify the Software. + +Object Code: means the binary files originating from the compilation of +the Source Code. + +Holder: means the holder(s) of the economic rights over the Initial +Software. + +Licensee: means the Software user(s) having accepted the Agreement. + +Contributor: means a Licensee having made at least one Contribution. + +Licensor: means the Holder, or any other individual or legal entity, who +distributes the Software under the Agreement. + +Contribution: means any or all modifications, corrections, translations, +adaptations and/or new functions integrated into the Software by any or +all Contributors, as well as any or all Internal Modules. + +Module: means a set of sources files including their documentation that +enables supplementary functions or services in addition to those offered +by the Software. + +External Module: means any or all Modules, not derived from the +Software, so that this Module and the Software run in separate address +spaces, with one calling the other when they are run. + +Internal Module: means any or all Module, connected to the Software so +that they both execute in the same address space. + +GNU GPL: means the GNU General Public License version 2 or any +subsequent version, as published by the Free Software Foundation Inc. + +GNU Affero GPL: means the GNU Affero General Public License version 3 or +any subsequent version, as published by the Free Software Foundation Inc. + +EUPL: means the European Union Public License version 1.1 or any +subsequent version, as published by the European Commission. + +Parties: mean both the Licensee and the Licensor. + +These expressions may be used both in singular and plural form. + + + Article 2 - PURPOSE + +The purpose of the Agreement is the grant by the Licensor to the +Licensee of a non-exclusive, transferable and worldwide license for the +Software as set forth in Article 5 <#scope> hereinafter for the whole +term of the protection granted by the rights over said Software. + + + Article 3 - ACCEPTANCE + +3.1 The Licensee shall be deemed as having accepted the terms and +conditions of this Agreement upon the occurrence of the first of the +following events: + + * (i) loading the Software by any or all means, notably, by + downloading from a remote server, or by loading from a physical medium; + * (ii) the first time the Licensee exercises any of the rights granted + hereunder. + +3.2 One copy of the Agreement, containing a notice relating to the +characteristics of the Software, to the limited warranty, and to the +fact that its use is restricted to experienced users has been provided +to the Licensee prior to its acceptance as set forth in Article 3.1 +<#accepting> hereinabove, and the Licensee hereby acknowledges that it +has read and understood it. + + + Article 4 - EFFECTIVE DATE AND TERM + + + 4.1 EFFECTIVE DATE + +The Agreement shall become effective on the date when it is accepted by +the Licensee as set forth in Article 3.1 <#accepting>. + + + 4.2 TERM + +The Agreement shall remain in force for the entire legal term of +protection of the economic rights over the Software. + + + Article 5 - SCOPE OF RIGHTS GRANTED + +The Licensor hereby grants to the Licensee, who accepts, the following +rights over the Software for any or all use, and for the term of the +Agreement, on the basis of the terms and conditions set forth hereinafter. + +Besides, if the Licensor owns or comes to own one or more patents +protecting all or part of the functions of the Software or of its +components, the Licensor undertakes not to enforce the rights granted by +these patents against successive Licensees using, exploiting or +modifying the Software. If these patents are transferred, the Licensor +undertakes to have the transferees subscribe to the obligations set +forth in this paragraph. + + + 5.1 RIGHT OF USE + +The Licensee is authorized to use the Software, without any limitation +as to its fields of application, with it being hereinafter specified +that this comprises: + + 1. permanent or temporary reproduction of all or part of the Software + by any or all means and in any or all form. + + 2. loading, displaying, running, or storing the Software on any or all + medium. + + 3. entitlement to observe, study or test its operation so as to + determine the ideas and principles behind any or all constituent + elements of said Software. This shall apply when the Licensee + carries out any or all loading, displaying, running, transmission or + storage operation as regards the Software, that it is entitled to + carry out hereunder. + + + 5.2 ENTITLEMENT TO MAKE CONTRIBUTIONS + +The right to make Contributions includes the right to translate, adapt, +arrange, or make any or all modifications to the Software, and the right +to reproduce the resulting software. + +The Licensee is authorized to make any or all Contributions to the +Software provided that it includes an explicit notice that it is the +author of said Contribution and indicates the date of the creation thereof. + + + 5.3 RIGHT OF DISTRIBUTION + +In particular, the right of distribution includes the right to publish, +transmit and communicate the Software to the general public on any or +all medium, and by any or all means, and the right to market, either in +consideration of a fee, or free of charge, one or more copies of the +Software by any means. + +The Licensee is further authorized to distribute copies of the modified +or unmodified Software to third parties according to the terms and +conditions set forth hereinafter. + + + 5.3.1 DISTRIBUTION OF SOFTWARE WITHOUT MODIFICATION + +The Licensee is authorized to distribute true copies of the Software in +Source Code or Object Code form, provided that said distribution +complies with all the provisions of the Agreement and is accompanied by: + + 1. a copy of the Agreement, + + 2. a notice relating to the limitation of both the Licensor's warranty + and liability as set forth in Articles 8 and 9, + +and that, in the event that only the Object Code of the Software is +redistributed, the Licensee allows effective access to the full Source +Code of the Software for a period of at least three years from the +distribution of the Software, it being understood that the additional +acquisition cost of the Source Code shall not exceed the cost of the +data transfer. + + + 5.3.2 DISTRIBUTION OF MODIFIED SOFTWARE + +When the Licensee makes a Contribution to the Software, the terms and +conditions for the distribution of the resulting Modified Software +become subject to all the provisions of this Agreement. + +The Licensee is authorized to distribute the Modified Software, in +source code or object code form, provided that said distribution +complies with all the provisions of the Agreement and is accompanied by: + + 1. a copy of the Agreement, + + 2. a notice relating to the limitation of both the Licensor's warranty + and liability as set forth in Articles 8 and 9, + +and, in the event that only the object code of the Modified Software is +redistributed, + + 3. a note stating the conditions of effective access to the full source + code of the Modified Software for a period of at least three years + from the distribution of the Modified Software, it being understood + that the additional acquisition cost of the source code shall not + exceed the cost of the data transfer. + + + 5.3.3 DISTRIBUTION OF EXTERNAL MODULES + +When the Licensee has developed an External Module, the terms and +conditions of this Agreement do not apply to said External Module, that +may be distributed under a separate license agreement. + + + 5.3.4 COMPATIBILITY WITH OTHER LICENSES + +The Licensee can include a code that is subject to the provisions of one +of the versions of the GNU GPL, GNU Affero GPL and/or EUPL in the +Modified or unmodified Software, and distribute that entire code under +the terms of the same version of the GNU GPL, GNU Affero GPL and/or EUPL. + +The Licensee can include the Modified or unmodified Software in a code +that is subject to the provisions of one of the versions of the GNU GPL, +GNU Affero GPL and/or EUPL and distribute that entire code under the +terms of the same version of the GNU GPL, GNU Affero GPL and/or EUPL. + + + Article 6 - INTELLECTUAL PROPERTY + + + 6.1 OVER THE INITIAL SOFTWARE + +The Holder owns the economic rights over the Initial Software. Any or +all use of the Initial Software is subject to compliance with the terms +and conditions under which the Holder has elected to distribute its work +and no one shall be entitled to modify the terms and conditions for the +distribution of said Initial Software. + +The Holder undertakes that the Initial Software will remain ruled at +least by this Agreement, for the duration set forth in Article 4.2 <#term>. + + + 6.2 OVER THE CONTRIBUTIONS + +The Licensee who develops a Contribution is the owner of the +intellectual property rights over this Contribution as defined by +applicable law. + + + 6.3 OVER THE EXTERNAL MODULES + +The Licensee who develops an External Module is the owner of the +intellectual property rights over this External Module as defined by +applicable law and is free to choose the type of agreement that shall +govern its distribution. + + + 6.4 JOINT PROVISIONS + +The Licensee expressly undertakes: + + 1. not to remove, or modify, in any manner, the intellectual property + notices attached to the Software; + + 2. to reproduce said notices, in an identical manner, in the copies of + the Software modified or not. + +The Licensee undertakes not to directly or indirectly infringe the +intellectual property rights on the Software of the Holder and/or +Contributors, and to take, where applicable, vis-à-vis its staff, any +and all measures required to ensure respect of said intellectual +property rights of the Holder and/or Contributors. + + + Article 7 - RELATED SERVICES + +7.1 Under no circumstances shall the Agreement oblige the Licensor to +provide technical assistance or maintenance services for the Software. + +However, the Licensor is entitled to offer this type of services. The +terms and conditions of such technical assistance, and/or such +maintenance, shall be set forth in a separate instrument. Only the +Licensor offering said maintenance and/or technical assistance services +shall incur liability therefor. + +7.2 Similarly, any Licensor is entitled to offer to its licensees, under +its sole responsibility, a warranty, that shall only be binding upon +itself, for the redistribution of the Software and/or the Modified +Software, under terms and conditions that it is free to decide. Said +warranty, and the financial terms and conditions of its application, +shall be subject of a separate instrument executed between the Licensor +and the Licensee. + + + Article 8 - LIABILITY + +8.1 Subject to the provisions of Article 8.2, the Licensee shall be +entitled to claim compensation for any direct loss it may have suffered +from the Software as a result of a fault on the part of the relevant +Licensor, subject to providing evidence thereof. + +8.2 The Licensor's liability is limited to the commitments made under +this Agreement and shall not be incurred as a result of in particular: +(i) loss due the Licensee's total or partial failure to fulfill its +obligations, (ii) direct or consequential loss that is suffered by the +Licensee due to the use or performance of the Software, and (iii) more +generally, any consequential loss. In particular the Parties expressly +agree that any or all pecuniary or business loss (i.e. loss of data, +loss of profits, operating loss, loss of customers or orders, +opportunity cost, any disturbance to business activities) or any or all +legal proceedings instituted against the Licensee by a third party, +shall constitute consequential loss and shall not provide entitlement to +any or all compensation from the Licensor. + + + Article 9 - WARRANTY + +9.1 The Licensee acknowledges that the scientific and technical +state-of-the-art when the Software was distributed did not enable all +possible uses to be tested and verified, nor for the presence of +possible defects to be detected. In this respect, the Licensee's +attention has been drawn to the risks associated with loading, using, +modifying and/or developing and reproducing the Software which are +reserved for experienced users. + +The Licensee shall be responsible for verifying, by any or all means, +the suitability of the product for its requirements, its good working +order, and for ensuring that it shall not cause damage to either persons +or properties. + +9.2 The Licensor hereby represents, in good faith, that it is entitled +to grant all the rights over the Software (including in particular the +rights set forth in Article 5 <#scope>). + +9.3 The Licensee acknowledges that the Software is supplied "as is" by +the Licensor without any other express or tacit warranty, other than +that provided for in Article 9.2 <#good-faith> and, in particular, +without any warranty as to its commercial value, its secured, safe, +innovative or relevant nature. + +Specifically, the Licensor does not warrant that the Software is free +from any error, that it will operate without interruption, that it will +be compatible with the Licensee's own equipment and software +configuration, nor that it will meet the Licensee's requirements. + +9.4 The Licensor does not either expressly or tacitly warrant that the +Software does not infringe any third party intellectual property right +relating to a patent, software or any other property right. Therefore, +the Licensor disclaims any and all liability towards the Licensee +arising out of any or all proceedings for infringement that may be +instituted in respect of the use, modification and redistribution of the +Software. Nevertheless, should such proceedings be instituted against +the Licensee, the Licensor shall provide it with technical and legal +expertise for its defense. Such technical and legal expertise shall be +decided on a case-by-case basis between the relevant Licensor and the +Licensee pursuant to a memorandum of understanding. The Licensor +disclaims any and all liability as regards the Licensee's use of the +name of the Software. No warranty is given as regards the existence of +prior rights over the name of the Software or as regards the existence +of a trademark. + + + Article 10 - TERMINATION + +10.1 In the event of a breach by the Licensee of its obligations +hereunder, the Licensor may automatically terminate this Agreement +thirty (30) days after notice has been sent to the Licensee and has +remained ineffective. + +10.2 A Licensee whose Agreement is terminated shall no longer be +authorized to use, modify or distribute the Software. However, any +licenses that it may have granted prior to termination of the Agreement +shall remain valid subject to their having been granted in compliance +with the terms and conditions hereof. + + + Article 11 - MISCELLANEOUS + + + 11.1 EXCUSABLE EVENTS + +Neither Party shall be liable for any or all delay, or failure to +perform the Agreement, that may be attributable to an event of force +majeure, an act of God or an outside cause, such as defective +functioning or interruptions of the electricity or telecommunications +networks, network paralysis following a virus attack, intervention by +government authorities, natural disasters, water damage, earthquakes, +fire, explosions, strikes and labor unrest, war, etc. + +11.2 Any failure by either Party, on one or more occasions, to invoke +one or more of the provisions hereof, shall under no circumstances be +interpreted as being a waiver by the interested Party of its right to +invoke said provision(s) subsequently. + +11.3 The Agreement cancels and replaces any or all previous agreements, +whether written or oral, between the Parties and having the same +purpose, and constitutes the entirety of the agreement between said +Parties concerning said purpose. No supplement or modification to the +terms and conditions hereof shall be effective as between the Parties +unless it is made in writing and signed by their duly authorized +representatives. + +11.4 In the event that one or more of the provisions hereof were to +conflict with a current or future applicable act or legislative text, +said act or legislative text shall prevail, and the Parties shall make +the necessary amendments so as to comply with said act or legislative +text. All other provisions shall remain effective. Similarly, invalidity +of a provision of the Agreement, for any reason whatsoever, shall not +cause the Agreement as a whole to be invalid. + + + 11.5 LANGUAGE + +The Agreement is drafted in both French and English and both versions +are deemed authentic. + + + Article 12 - NEW VERSIONS OF THE AGREEMENT + +12.1 Any person is authorized to duplicate and distribute copies of this +Agreement. + +12.2 So as to ensure coherence, the wording of this Agreement is +protected and may only be modified by the authors of the License, who +reserve the right to periodically publish updates or new versions of the +Agreement, each with a separate number. These subsequent versions may +address new issues encountered by Free Software. + +12.3 Any Software distributed under a given version of the Agreement may +only be subsequently distributed under the same version of the Agreement +or a subsequent version, subject to the provisions of Article 5.3.4 +<#compatibility>. + + + Article 13 - GOVERNING LAW AND JURISDICTION + +13.1 The Agreement is governed by French law. The Parties agree to +endeavor to seek an amicable solution to any disagreements or disputes +that may arise during the performance of the Agreement. + +13.2 Failing an amicable solution within two (2) months as from their +occurrence, and unless emergency proceedings are necessary, the +disagreements or disputes shall be referred to the Paris Courts having +jurisdiction, by the more diligent Party. diff -r 000000000000 -r ad06aeed02c9 README.md --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/README.md Tue Aug 02 06:26:41 2016 -0400 @@ -0,0 +1,60 @@ +## Heatmap of the data matrix +#### A Galaxy module from the [Workflow4metabolomics](http://workflow4metabolomics.org) project + +Status: [![Build Status](https://travis-ci.org/workflow4metabolomics/heatmap.svg?branch=master)](https://travis-ci.org/workflow4metabolomics/heatmap). + +### Description + +**Version:** 2.2.0 +**Date:** 2016-07-30 +**Author:** Etienne A. Thevenot (CEA, LIST, MetaboHUB, W4M Core Development Team) +**Email:** [etienne.thevenot(at)cea.fr](mailto:etienne.thevenot@cea.fr) +**Citation:** Thevenot E.A., Roux A., Xu Y., Ezan E. and Junot C. (2015). Analysis of the human adult urinary metabolome variations with age, body mass index and gender by implementing a comprehensive workflow for univariate and OPLS statistical analyses. *Journal of Proteome Research*, **14**:3322-3335. [doi:10.1021/acs.jproteome.5b00354](http://dx.doi.org/10.1021/acs.jproteome.5b00354) +**Licence:** CeCILL +**Reference history:** [W4M00001a_sacurine-subset-statistics](http://galaxy.workflow4metabolomics.org/history/list_published) +**Funding:** Agence Nationale de la Recherche ([MetaboHUB](http://www.metabohub.fr/index.php?lang=en&Itemid=473) national infrastructure for metabolomics and fluxomics, ANR-11-INBS-0010 grant) + +### Installation + +* Configuration file: **heatmap_config.xml** +* Image files: + + **static/images/heatmap_workflowPositionImage.png** + + **static/images/heatmap_workingExampleImage.png** +* Wrapper file: **heatmap_wrapper.R** +* R packages + + **batch** from CRAN +> install.packages("batch", dep=TRUE) + +### Tests + +The code in the wrapper can be tested by running the **tests/heatmap_tests.R** in R + +### News + +##### CHANGES IN VERSION 2.2.0 + +NEW FEATURES + + o Default method for the correlation coefficient is now 'pearson', instead of 'spearman' previously (the latter can still be selected in the advanced parameters) + + o The 1-abs(correlation) dissimilarity is now available (in addition to the default '1-correlation') in case the sign of correlations between samples and between variables does not matter, as well as the euclidean, maximum, manhattan, canberra, binary, and minkowski dissimilarities + + o A new red-green color scale is available + +*** + +##### CHANGES IN VERSION 2.1.2 + +INTERNAL MODIFICATION + + o Creating additional files for planemo and travis validation + +*** + +##### CHANGES IN VERSION 2.0.2 + +INTERNAL MODIFICATION + + o Creating tests for R code + +*** \ No newline at end of file diff -r 000000000000 -r ad06aeed02c9 build.xml --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/build.xml Tue Aug 02 06:26:41 2016 -0400 @@ -0,0 +1,78 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff -r 000000000000 -r ad06aeed02c9 heatmap_config.xml --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/heatmap_config.xml Tue Aug 02 06:26:41 2016 -0400 @@ -0,0 +1,345 @@ + + Heatmap of the dataMatrix + + + R + r-batch + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +.. class:: infomark + +| **Tool update: See the 'NEWS' section at the bottom of the page** + +--------------------------------------------------- + +.. class:: infomark + +**Author** Etienne Thevenot (W4M Core Development Team, MetaboHUB Paris, CEA) + +--------------------------------------------------- + +.. class:: infomark + +**References** + +| Etienne A. Thevenot, Aurelie Roux, Ying Xu, Eric Ezan, and Christophe Junot (2015). Analysis of the human adult urinary metabolome variations with age, body mass index and gender by implementing a comprehensive workflow for univariate and OPLS statistical analyses. *Journal of Proteome Research*, **14**:3322-3335 (http://dx.doi.org/10.1021/acs.jproteome.5b00354). +| R Core Team (2013). R: A language and environment for statistical computing. R Foundation for Statistical Computing, Vienna, Austria (http://www.r-project.org) +| + +--------------------------------------------------- + +.. class:: infomark + +**Tool updates** + +See the **NEWS** section at the bottom of this page + +--------------------------------------------------- + + +======================== +Heatmap +======================== + +----------- +Description +----------- + + | Performs hierarchical clustering on both the samples (rows) and variables (columns) of the dataMatrix + | Displays the dataMatrix with sorted rows and samples and the dendrograms (heatmap) + | In the output dataMatrix, sampleMetadata and variableMetadata files sample and variables are sorted according to the dendrograms + | Optionally, indicates the groups of samples and/or variables obtained by cutting the dendrograms into a specific number of partitions + | + | Note: 1) Computations rely on the 'hclust' function. The dissimilarity is 1 - cor (where cor is the Spearman correlation) and the 'ward.D' aggregating method is used. + | 2) A "blue-orange-red" palette is generated with the function 'colorRampPalette'; **By default, variables are standardized (mean-centered and unit-scaled) to enhance contrast on the figure**; standardization can be turned off by using the full list of parameters; in any case, standardizing is performed after the computation of clusters, for display only + | 3) When a specific number of sample and/or variable groups (i.e. > 1) are selected, the group numbers are indicated on the plot and in an additional 'heat_clust" column in the sampleMetadata and/or variableMetadata + | 4) Example of computation times: for 126 variables: a few seconds; for 4324 variables: 30 min + | + + +----------------- +Workflow position +----------------- + +| In the workflow example below, the structure of the dataset (dataMatrix) is visualized by using first the "Quality Metrics" (for checking potential signal drift, sample outliers, etc.), then the "Heatmap" (for correlations between samples or variables), and finally the "Multivariate" (for PCA or PLS) modules. +| + +.. image:: heatmap_workflowPositionImage.png + :width: 600 + + + +----------- +Input files +----------- + ++--------------------------+-------------+ +| File type | Format | ++==========================+=============+ +| 1 : Data matrix | tabular | ++--------------------------+-------------+ +| 2 : Sample metadata | tabular | ++--------------------------+-------------+ +| 3 : Variable metadata | tabular | ++--------------------------+-------------+ + +| +| Required formats for the dataMatrix, sampleMetadata and variableMetadata files are described in the HowTo entitled 'Format Data For Postprocessing' available on the main page of Workflow4Metabolomics.org; formats of the three files can be further checked with the 'Check Data' module (in the 'Quality Control' section) +| + +---------- +Parameters +---------- + +Number of sample clusters + | By default (cluster = 1), only dendrograms are displayed; when a specific number of sample clusters is selected, the sample dendrogram is cut at the corresponding level: the sample groups are displayed on the dendrogram and a "heat_clust" column is added in the sampleMetadata file with the group of each sample + | + +Number of variable clusters + | Same as above for variables + | + +Standardization (Full list) + | By default, variables are standardized for display to enhance contrast of the heatmap (note that standardization is performed after the clustering for display only and does not modify cluster computation nor intensities in the output files) + | + +Size of labels (Full list) + | The size of sample and variable names on the heatmap is 0.8 (note that names with more than 14 characters are truncated); this number may be lowered (or uppered) in case of many (few) names to display + + +------------ +Output files +------------ + +dataMatrix_out.tabular + | dataMatrix file with rows and columns sorted according to the dendrogram + | + +sampleMetadata_out.tabular + | sampleMetadata file with rows sorted according to the sample dendrogram; in case a number of sample groups is specified, and additional "heat_clust" column is added with the cluster group of each sample + | + +variableMetadata_out.tabular + | variableMetadata file with rows sorted according to the variable dendrogram; in case a number of variable groups is specified, and additional "heat_clust" column is added with the cluster group of each variable + | + +figure.pdf + | Heatmap + | + +information.txt + | File with all messages and warnings generated during the computation + | + +--------------------------------------------------- + +--------------- +Working example +--------------- + +.. class:: infomark + +See the **W4M00001a_sacurine-subset-statistics** shared history in the **Shared Data/Published Histories** menu + +--------------------------------------------------- + +---- +NEWS +---- + +CHANGES IN VERSION 2.2.0 +======================== + +NEW FEATURES + +Default method for the correlation coefficient is now 'pearson', instead of 'spearman' previously (the latter can still be selected in the advanced parameters) + +The 1-abs(correlation) dissimilarity is now available (in addition to the default '1-correlation') in case the sign of correlations between samples and between variables does not matter, as well as the euclidean, maximum, manhattan, canberra, binary, and minkowski dissimilarities + +A new red-green color scale is available + + +CHANGES IN VERSION 2.1.2 +======================== + +INTERNAL MODIFICATIONS + +Creating additional files for planemo and travis running and installation validation + +CHANGES IN VERSION 2.1.1 +======================== + +Internal replacement of the as.hclust function which happened to produce error messages + + + + + @Article{Thevenot2015, + Title = {Analysis of the human adult urinary metabolome variations with age, body mass index and gender by implementing a comprehensive workflow for univariate and OPLS statistical analyses}, + Author = {Thevenot, Etienne A. and Roux, Aurelie and Xu, Ying and Ezan, Eric and Junot, Christophe}, + Journal = {Journal of Proteome Research}, + Year = {2015}, + Note = {PMID: 26088811}, + Number = {8}, + Pages = {3322-3335}, + Volume = {14}, + + Doi = {10.1021/acs.jproteome.5b00354}, + Url = {http://pubs.acs.org/doi/full/10.1021/acs.jproteome.5b00354} + } + + + diff -r 000000000000 -r ad06aeed02c9 heatmap_script.R --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/heatmap_script.R Tue Aug 02 06:26:41 2016 -0400 @@ -0,0 +1,258 @@ +## Etienne Thevenot +## CEA, MetaboHUB +## W4M Core Development Team +## etienne.thevenot@cea.fr +## 2015-05-30 + + +heatmapF <- function(proMN, + obsDF, + feaDF, + disC, ## dissimilarity + cutSamN, ## number of sample clusters + cutVarN, ## number of variable clusters + fig.pdfC, + corMetC, ## correlation method + aggMetC, ## agglomeration method + colC, ## color scale + scaL, + cexN) { + + ncaN <- 14 ## Sample and variable name truncature for display + + if(aggMetC == "ward") { + + rvsLs <- R.Version() + aggMetC <- paste0(aggMetC, + ifelse(as.numeric(rvsLs[["major"]]) > 3 || + as.numeric(rvsLs[["major"]]) == 3 && as.numeric(rvsLs[["minor"]]) > 0.3, + ".D", + "")) + + } + + if(disC %in% c("euclidean", "maximum", "manhattan", "canberra", "binary", "minkowski")) { + + obsHcl <- hclust(dist(proMN, method = disC), + method = aggMetC) + + feaHcl <- hclust(dist(t(proMN), method = disC), + method = aggMetC) + + } else if(disC == "1-cor") { + + obsHcl <- hclust(as.dist(1-cor(t(proMN), + method = corMetC, + use = "pairwise.complete.obs")), + method = aggMetC) + + feaHcl <- hclust(as.dist(1-cor(proMN, + method = corMetC, + use = "pairwise.complete.obs")), + method = aggMetC) + + } else if(disC == "1-abs(cor)") { + + obsHcl <- hclust(as.dist(1-abs(cor(t(proMN), + method = corMetC, + use = "pairwise.complete.obs"))), + method = aggMetC) + + feaHcl <- hclust(as.dist(1-abs(cor(proMN, + method = corMetC, + use = "pairwise.complete.obs"))), + method = aggMetC) + + } + + heaMN <- proMN <- proMN[obsHcl[["order"]], feaHcl[["order"]]] + + if(scaL) + heaMN <- scale(heaMN) + + heaMN <- heaMN[, rev(1:ncol(heaMN)), drop = FALSE] + + switch(colC, + blueOrangeRed = { + imaPalVn <- colorRampPalette(c("blue", "orange", "red"), + space = "rgb")(5)[1:5] + }, + redBlackGreen = { + imaPalVn <- colorRampPalette(c("red", "black", "green"), + space = "rgb")(5)[1:5] + }) + + + ## figure + ##------- + + pdf(fig.pdfC, + width = 14, + height = 14) + + layout(matrix(1:4, nrow = 2), + widths = c(1, 9), heights = c(1, 9)) + + ## Color scale + + scaN <- length(imaPalVn) + + par(mar = c(0.6, 0.6, 0.6, 4.1)) + + ylimVn <- c(0, scaN) + ybottomVn <- 0:(scaN - 1) + ytopVn <- 1:scaN + + plot(x = 0, + y = 0, + bty = "n", + font.axis = 2, + font.lab = 2, + type = "n", + xlim = c(0, 1), + ylim = ylimVn, + xlab = "", + ylab = "", + xaxs = "i", + yaxs = "i", + xaxt = "n", + yaxt = "n") + + rect(xleft = 0.8, + ybottom = ybottomVn, + xright = 1, + ytop = ytopVn, + col = imaPalVn, + border = NA) + + prtVn <- pretty(range(heaMN, na.rm = TRUE)) + axis(at = scaN / diff(range(prtVn)) * (prtVn - min(prtVn)), + font = 2, + font.axis = 2, + labels = prtVn, + las = 1, + lwd = 2, + lwd.ticks = 2, + side = 4, + xpd = TRUE) + + arrows(par("usr")[2], + par("usr")[4], + par("usr")[2], + par("usr")[3], + code = 0, + lwd = 2, + xpd = TRUE) + + ## Feature dendrogram + + par(mar = c(7.1, 0.6, 0, 0.1), + lwd = 2) + + plot(rev(as.dendrogram(feaHcl)), horiz = TRUE, + leaflab = "none", + main = "", xaxs = "i", yaxs = "i", + xaxt = "n", yaxt = "n", xlab = "", ylab = "") + + revFeaHcl <- list(merge = cbind(feaHcl[["merge"]][, 2], feaHcl[["merge"]][, 1]), + height = feaHcl[["height"]], + order = rev(feaHcl[["order"]]), + labels = feaHcl[["labels"]]) + + if(cutVarN > 1) { + cluFeaVn <- cutree(revFeaHcl, k = cutVarN)[revFeaHcl[["order"]]] + cutFeaVn <- which(abs(diff(cluFeaVn)) > 0) + cutFeaTxtVn <- c(cutFeaVn[1] / 2, cutFeaVn + diff(c(cutFeaVn, length(cluFeaVn))) / 2) + 0.5 + cutFeaLinVn <- cutFeaVn + 0.5 + text(par("usr")[1] + 0.2 * diff(par("usr")[1:2]), + cutFeaTxtVn, + labels = unique(cluFeaVn), + cex = 2, + font = 2, + las = 2) + } + + ## Observation dendrogram + + par(mar = c(0.1, 0, 0.6, 7.1), + lwd = 2) + + plot(as.dendrogram(obsHcl), leaflab = "none", + main = "", xaxs = "i", yaxs = "i", + yaxt = "n", xlab = "", ylab = "") + + if(cutSamN > 1) { + cluObsVn <- cutree(obsHcl, k = cutSamN)[obsHcl[["order"]]] + cutObsVn <- which(abs(diff(cluObsVn)) > 0) + cutObsTxtVn <- c(cutObsVn[1] / 2, cutObsVn + diff(c(cutObsVn, length(cluObsVn))) / 2) + 0.5 + cutObsLinVn <- cutObsVn + 0.5 + text(cutObsTxtVn, + 0.8 * par("usr")[4], + labels = unique(cluObsVn), + cex = 2, + font = 2) + } + + ## Heatmap + + par(mar = c(7.1, 0, 0, 7.1)) + + image(x = 1:nrow(heaMN), + y = 1:ncol(heaMN), + z = round(heaMN), + col = imaPalVn, + font.axis = 2, + font.lab = 2, + xaxt = "n", + yaxt = "n", + xlab = "", + ylab = "") + + obsOrdVc <- obsHcl[["labels"]][obsHcl[["order"]]] + obsOrdLenVn <- sapply(obsOrdVc, nchar) + obsOrdVc <- substr(obsOrdVc, 1, ncaN) + obsOrdVc <- paste0(obsOrdVc, ifelse(obsOrdLenVn > ncaN, ".", ""), " ") + + mtext(obsOrdVc, + at = 1:nrow(heaMN), + cex = cexN, + las = 2, + side = 1) + + feaOrdVc <- feaHcl[["labels"]][feaHcl[["order"]]] + feaOrdLenVn <- sapply(feaOrdVc, nchar) + feaOrdVc <- substr(feaOrdVc, 1, ncaN) + feaOrdVc <- paste0(" ", feaOrdVc, ifelse(feaOrdLenVn > ncaN, ".", "")) + + mtext(feaOrdVc, + at = ncol(heaMN):1, + cex = cexN, + las = 2, + side = 4) + + if(cutVarN > 1) + abline(h = cutFeaLinVn) + if(cutSamN > 1) + abline(v = cutObsLinVn) + + box() + + dev.off() + + ## Returning + ##---------- + + if(cutSamN > 1) + obsDF[, "heat_clust"] <- cutree(obsHcl, k = cutSamN) + obsDF <- obsDF[obsHcl[["order"]], , drop = FALSE] + + if(cutVarN > 1) + feaDF[, "heat_clust"] <- cutree(feaHcl, k = cutVarN) + feaDF <- feaDF[feaHcl[["order"]], , drop = FALSE] + + return(invisible(list(proMN = proMN, + obsDF = obsDF, + feaDF = feaDF))) + + +} ## end of heatmapF diff -r 000000000000 -r ad06aeed02c9 heatmap_wrapper.R --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/heatmap_wrapper.R Tue Aug 02 06:26:41 2016 -0400 @@ -0,0 +1,156 @@ +#!/usr/bin/env Rscript + +library(batch) ## parseCommandArgs + +source_local <- function(fname){ + argv <- commandArgs(trailingOnly = FALSE) + base_dir <- dirname(substring(argv[grep("--file=", argv)], 8)) + source(paste(base_dir, fname, sep="/")) +} + +source_local("heatmap_script.R") + +argVc <- unlist(parseCommandArgs(evaluate=FALSE)) + + +##------------------------------ +## Initializing +##------------------------------ + +## options +##-------- + +strAsFacL <- options()[["stringsAsFactors"]] +options(stringsAsFactors=FALSE) + +## constants +##---------- + +modNamC <- "Heatmap" ## module name + +## log file +##--------- + +sink(argVc["information"]) + +cat("\nStart of the '", modNamC, "' module: ", + format(Sys.time(), "%a %d %b %Y %X"), "\n", sep="") + +## loading +##-------- + +proMN <- t(as.matrix(read.table(argVc["dataMatrix_in"], + check.names = FALSE, + header = TRUE, + row.names = 1, + sep = "\t"))) + +obsDF <- read.table(argVc["sampleMetadata_in"], + check.names = FALSE, + header = TRUE, + row.names = 1, + sep = "\t") + +feaDF <- read.table(argVc["variableMetadata_in"], + check.names = FALSE, + header = TRUE, + row.names = 1, + sep = "\t") + +## adding default parameter values +##-------------------------------- + + +if(!("corMetC" %in% names(argVc))) + argVc["corMetC"] <- "pearson" +if(!("aggMetC" %in% names(argVc))) + argVc["aggMetC"] <- "ward" +if(!("colC" %in% names(argVc))) + argVc["colC"] <- "blueOrangeRed" +if(!("scaL" %in% names(argVc))) + argVc["scaL"] <- "TRUE" +if(!("cexN" %in% names(argVc))) + argVc["cexN"] <- "0.8" + +## checking +##--------- + +if(as.numeric(argVc["cutSamN"]) > nrow(proMN)) + stop("Number of sample clusters must be inferior to the number of samples") +if(as.numeric(argVc["cutVarN"]) > ncol(proMN)) + stop("Number of variable clusters must be inferior to the number of variables") + +## printing arguments +##------------------- + +cat("\nArguments used:\n\n") +argMC <- as.matrix(argVc) +colnames(argMC) <- "value" +argDatVl <- grepl("\\.dat$", argVc) ## discarding dataset file names +if(sum(argDatVl)) + argMC <- argMC[!argDatVl, , drop = FALSE] +print(argMC) + + +##------------------------------ +## Computation +##------------------------------ + + +heaLs <- heatmapF(proMN = proMN, + obsDF = obsDF, + feaDF = feaDF, + disC = argVc["disC"], + cutSamN = as.numeric(argVc["cutSamN"]), + cutVarN = as.numeric(argVc["cutVarN"]), + fig.pdfC = argVc["figure"], + corMetC = argVc["corMetC"], + aggMetC = argVc["aggMetC"], + colC = argVc["colC"], + scaL = as.logical(argVc["scaL"]), + cexN = as.numeric(argVc["cexN"])) + + +##------------------------------ +## Ending +##------------------------------ + + +## saving +##------- + +proDF <- cbind.data.frame(dataMatrix = colnames(heaLs[["proMN"]]), + as.data.frame(t(heaLs[["proMN"]]))) +write.table(proDF, + file = argVc["dataMatrix_out"], + quote = FALSE, + row.names = FALSE, + sep = "\t") + +obsDF <- cbind.data.frame(sampleMetadata = rownames(heaLs[["obsDF"]]), + heaLs[["obsDF"]]) +write.table(obsDF, + file = argVc["sampleMetadata_out"], + quote = FALSE, + row.names = FALSE, + sep = "\t") + +feaDF <- cbind.data.frame(variableMetadata = rownames(heaLs[["feaDF"]]), + heaLs[["feaDF"]]) +write.table(feaDF, + file = argVc["variableMetadata_out"], + quote = FALSE, + row.names = FALSE, + sep = "\t") + +## Ending +##------- + +cat("\nEnd of the '", modNamC, "' Galaxy module call: ", + format(Sys.time(), "%a %d %b %Y %X"), "\n", sep = "") + +sink() + +options(stringsAsFactors = strAsFacL) + +rm(list = ls()) diff -r 000000000000 -r ad06aeed02c9 static/images/heatmap_workflowPositionImage.png Binary file static/images/heatmap_workflowPositionImage.png has changed diff -r 000000000000 -r ad06aeed02c9 static/images/heatmap_workingExampleImage.png Binary file static/images/heatmap_workingExampleImage.png has changed diff -r 000000000000 -r ad06aeed02c9 test-data/input-dataMatrix.tsv --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/test-data/input-dataMatrix.tsv Tue Aug 02 06:26:41 2016 -0400 @@ -0,0 +1,16 @@ +dataMatrix HU_017 HU_028 HU_034 HU_051 HU_060 HU_078 HU_091 HU_093 HU_099 HU_110 HU_130 HU_134 HU_138 HU_149 HU_152 HU_175 HU_178 HU_185 HU_204 HU_208 +HMDB03193 76043 412165 44943 27242 436566 173175 242549 57066 559869 3732 339188 471368 262271 127285 451270 212500 79673 NA 891129 43907 +HMDB01101 30689 6877586 52217 3158 10789748 229568 4763576 3878773 976436 831937 608298 1605075 72021 442510 1107705 1464339 31250 2724553 72900 32742 +HMDB10348 47259 544877 60885 34582 529874 168264 176500 76457 610110 16262 279156 524468 451573 591487 433529 161069 214392 13781 1580343 39315 +HMDB59717 357351 1030464 301983 67604 306862 1028110 1530493 270027 1378535 289677 808334 1132813 871209 895435 715190 1563158 784738 146195 994336 239030 +HMDB00822 483755 579287 1132413 157113 1577570 1469735 1085454 477909 814755 245417 610681 763706 2406336 827531 992508 569605 355321 150259 1334200 271010 +HMDB13189 2644620 727587 1661412 619181 136278 2755434 593863 837865 3526136 2003278 1608814 3446611 1941527 113937 3132404 2893445 2092753 1034666 1517319 841661 +HMDB00299 250551 1046138 456162 159386 1013302 808657 614370 250403 768004 242085 504108 1014041 1362408 1057660 1110050 566050 411886 142233 1992420 284775 +HMDB00191 560002 771533 575790 392284 888498 785428 645785 591569 960658 910201 639437 1092885 1409045 2292023 1246459 1945577 710519 773384 1061418 622898 +HMDB00518 34236 58249 85944 NA 342102 129886 175800 13154 230242 NA 440223 315368 10657 419508 48673 28361 514579 23108 867108 73831 +HMDB00715 1252089 2547452 905408 371059 4983588 5140022 2658555 814523 2558923 859466 4184204 3865723 3236644 2615560 3820724 3577833 2295288 625924 7517724 1341900 +HMDB01032 2569205 26023086 1604999 430453 8103558 26222916 257139 675754 59906109 263055 31151730 18648127 14989438 1554658 20249262 5588731 871010 15920 9120781 44276 +HMDB00208 747080 13420742 595872 1172376 7172632 3143654 4059767 1433702 5593888 5402629 2477288 3346077 4230072 7621236 8960828 10335722 7037373 1574738 3359238 2540044 +HMDB04824 374028 1144386 539206 178517 1046190 959381 605191 310260 1253319 477259 477995 825691 1157093 1089284 1411802 1020206 782673 346761 1824553 387811 +HMDB00512 53304 319783 280560 85009 1333877 556003 590779 209285 342532 198512 569970 525240 246282 1140422 542345 1171008 827723 222953 438839 85554 +HMDB00251 368600 616555 94936 622468 180988 293988 352855 767894 268331 167246 310918 1248919 577184 10985 335711 403815 80614 63393 454489 616061 diff -r 000000000000 -r ad06aeed02c9 test-data/input-sampleMetadata.tsv --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/test-data/input-sampleMetadata.tsv Tue Aug 02 06:26:41 2016 -0400 @@ -0,0 +1,21 @@ +sampleMetadata injectionOrder mode age bmi gender +HU_017 2 pos 41 23.03 M +HU_028 7 pos 41 23.92 F +HU_034 9 pos 52 23.37 M +HU_051 20 pos 24 23.23 F +HU_060 24 pos 55 28.72 F +HU_078 34 pos 46 25.18 M +HU_091 42 pos 61 26.12 M +HU_093 43 pos 53 21.71 M +HU_099 46 pos 23 21.3 M +HU_110 53 pos 50 20.9 F +HU_130 63 pos 33 26.06 M +HU_134 67 pos 48 22.89 M +HU_138 68 pos 42 21.88 M +HU_149 72 pos 35 19.49 F +HU_152 75 pos 26 17.58 F +HU_175 87 pos 35 21.26 F +HU_178 88 pos 60 32.87 F +HU_185 95 pos 42 21.09 F +HU_204 104 pos 31 29.06 M +HU_208 106 pos 27 18.61 F diff -r 000000000000 -r ad06aeed02c9 test-data/input-variableMetadata.tsv --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/test-data/input-variableMetadata.tsv Tue Aug 02 06:26:41 2016 -0400 @@ -0,0 +1,16 @@ +variableMetadata name +HMDB03193 Testosterone_glucuronide +HMDB01101 p-Anisic_acid +HMDB10348 Dehydroepiandrosterone_3-glucuronide +HMDB59717 Glu-Val +HMDB00822 p-Hydroxymandelic_acid +HMDB13189 3-Indole_carboxylic_acid_glucuronide +HMDB00299 Xanthosine +HMDB00191 L-Aspartic_acid +HMDB00518 Chenodeoxycholic_acid +HMDB00715 Kynurenic_acid +HMDB01032 Dehydroepiandrosterone_sulfate +HMDB00208 Oxoglutaric_acid +HMDB04824 N2,N2-Dimethylguanosine +HMDB00512 N-Acetyl-L-phenylalanine +HMDB00251 Taurine diff -r 000000000000 -r ad06aeed02c9 test-data/output-dataMatrix.tsv --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/test-data/output-dataMatrix.tsv Tue Aug 02 06:26:41 2016 -0400 @@ -0,0 +1,16 @@ +dataMatrix HU_051 HU_208 HU_178 HU_130 HU_175 HU_099 HU_152 HU_204 HU_017 HU_138 HU_034 HU_078 HU_060 HU_149 HU_028 HU_093 HU_134 HU_091 HU_110 HU_185 +HMDB13189 619181 841661 2092753 1608814 2893445 3526136 3132404 1517319 2644620 1941527 1661412 2755434 136278 113937 727587 837865 3446611 593863 2003278 1034666 +HMDB00251 622468 616061 80614 310918 403815 268331 335711 454489 368600 577184 94936 293988 180988 10985 616555 767894 1248919 352855 167246 63393 +HMDB01101 3158 32742 31250 608298 1464339 976436 1107705 72900 30689 72021 52217 229568 10789748 442510 6877586 3878773 1605075 4763576 831937 2724553 +HMDB00191 392284 622898 710519 639437 1945577 960658 1246459 1061418 560002 1409045 575790 785428 888498 2292023 771533 591569 1092885 645785 910201 773384 +HMDB00208 1172376 2540044 7037373 2477288 10335722 5593888 8960828 3359238 747080 4230072 595872 3143654 7172632 7621236 13420742 1433702 3346077 4059767 5402629 1574738 +HMDB59717 67604 239030 784738 808334 1563158 1378535 715190 994336 357351 871209 301983 1028110 306862 895435 1030464 270027 1132813 1530493 289677 146195 +HMDB00512 85009 85554 827723 569970 1171008 342532 542345 438839 53304 246282 280560 556003 1333877 1140422 319783 209285 525240 590779 198512 222953 +HMDB00518 NA 73831 514579 440223 28361 230242 48673 867108 34236 10657 85944 129886 342102 419508 58249 13154 315368 175800 NA 23108 +HMDB00822 157113 271010 355321 610681 569605 814755 992508 1334200 483755 2406336 1132413 1469735 1577570 827531 579287 477909 763706 1085454 245417 150259 +HMDB00715 371059 1341900 2295288 4184204 3577833 2558923 3820724 7517724 1252089 3236644 905408 5140022 4983588 2615560 2547452 814523 3865723 2658555 859466 625924 +HMDB01032 430453 44276 871010 31151730 5588731 59906109 20249262 9120781 2569205 14989438 1604999 26222916 8103558 1554658 26023086 675754 18648127 257139 263055 15920 +HMDB00299 159386 284775 411886 504108 566050 768004 1110050 1992420 250551 1362408 456162 808657 1013302 1057660 1046138 250403 1014041 614370 242085 142233 +HMDB04824 178517 387811 782673 477995 1020206 1253319 1411802 1824553 374028 1157093 539206 959381 1046190 1089284 1144386 310260 825691 605191 477259 346761 +HMDB03193 27242 43907 79673 339188 212500 559869 451270 891129 76043 262271 44943 173175 436566 127285 412165 57066 471368 242549 3732 NA +HMDB10348 34582 39315 214392 279156 161069 610110 433529 1580343 47259 451573 60885 168264 529874 591487 544877 76457 524468 176500 16262 13781 diff -r 000000000000 -r ad06aeed02c9 test-data/output-variableMetadata.tsv --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/test-data/output-variableMetadata.tsv Tue Aug 02 06:26:41 2016 -0400 @@ -0,0 +1,16 @@ +variableMetadata name heat_clust +HMDB13189 3-Indole_carboxylic_acid_glucuronide 3 +HMDB00251 Taurine 3 +HMDB01101 p-Anisic_acid 2 +HMDB00191 L-Aspartic_acid 2 +HMDB00208 Oxoglutaric_acid 2 +HMDB59717 Glu-Val 2 +HMDB00512 N-Acetyl-L-phenylalanine 2 +HMDB00518 Chenodeoxycholic_acid 1 +HMDB00822 p-Hydroxymandelic_acid 1 +HMDB00715 Kynurenic_acid 1 +HMDB01032 Dehydroepiandrosterone_sulfate 1 +HMDB00299 Xanthosine 1 +HMDB04824 N2,N2-Dimethylguanosine 1 +HMDB03193 Testosterone_glucuronide 1 +HMDB10348 Dehydroepiandrosterone_3-glucuronide 1 diff -r 000000000000 -r ad06aeed02c9 tests/exa1/dataMatrix.tsv --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/tests/exa1/dataMatrix.tsv Tue Aug 02 06:26:41 2016 -0400 @@ -0,0 +1,39 @@ +dataMatrix S1 S2 S3 S4 S5 S6 +V1 196502 237810 198284 182894 105331 132150 +V2 2544571 2614302 2451909 3142179 3768416 3713752 +V3 1230784 1161975 1143745 1150915 1344578 1220503 +V4 1630089 1818363 1563465 2387030 3502620 2954208 +V5 2184963 2374515 1974647 2313226 1782744 1860757 +V6 5262172 6365930 5010369 9109487 6410977 6378638 +V7 2232587 2745906 2200995 3832216 2708070 2869295 +V8 483320 660332 433486 1062013 677822 748514 +V9 112905 136174 123604 162138 240686 195271 +V10 179154 195001 180519 98623 132470 123032 +V11 175220 169515 158401 111215 103539 159727 +V12 46503 55313 76310 46932 92318 43629 +V13 113796 91557 95960 92685 140973 112898 +V14 540798 596737 511783 876548 1626199 1385367 +V15 140806 135469 145016 229518 434119 398941 +V16 1334798 1318651 1308783 2345055 4068874 3565724 +V17 1083792 1145232 916864 838363 1678307 1304234 +V18 91671 101007 79999 85402 146939 126314 +V19 274181 282331 292645 394175 330817 293481 +V20 879658 809068 903330 1273966 959314 938277 +V21 608434 662366 727426 920178 1106194 1201520 +V22 1600960 1545158 1608816 1880288 2246189 2069613 +V23 2171614 2239769 2106004 2565354 4913676 4072322 +V24 4045143 3862213 4053630 7352540 5574415 6185035 +V25 202805 182042 165499 57267 86611 89320 +V26 586997 667911 522193 748212 595063 659353 +V27 229790 256287 253497 1189248 1025521 746948 +V28 1644853 1759382 1760494 3379214 4572430 4386799 +V29 8491372 9275641 8655578 12105700 13265172 13484917 +V30 724039 730730 640992 1475658 1191085 1213210 +V31 86524840 89500400 88593487 183705591 150949959 169189091 +V32 26916143 30167854 28256416 39049936 45546213 47237473 +V33 2683733 2654918 2386486 4786536 3622659 3879731 +V34 3919797 4529379 3595989 7965534 5963667 6339219 +V35 84384696 90691983 83322980 51888441 86013709 79735533 +V36 95751916 101056674 92760886 129551865 109580811 118980909 +V37 374328 416298 355931 255675 371223 338701 +V38 2219529 2333885 2206832 903780 981633 1136522 diff -r 000000000000 -r ad06aeed02c9 tests/exa1/sampleMetadata.tsv --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/tests/exa1/sampleMetadata.tsv Tue Aug 02 06:26:41 2016 -0400 @@ -0,0 +1,7 @@ +sampleMetadata smeta1 smeta2 +S1 196502 2544571 +S2 237810 2614302 +S3 198284 2451909 +S4 182894 3142179 +S5 105331 3768416 +S6 132150 3713752 diff -r 000000000000 -r ad06aeed02c9 tests/exa1/variableMetadata.tsv --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/tests/exa1/variableMetadata.tsv Tue Aug 02 06:26:41 2016 -0400 @@ -0,0 +1,39 @@ +variableMetadata vmeta1 vmeta2 vmeta3 vmeta4 vmeta5 vmeta6 +V1 196502 237810 198284 182894 105331 132150 +V2 2544571 2614302 2451909 3142179 3768416 3713752 +V3 1230784 1161975 1143745 1150915 1344578 1220503 +V4 1630089 1818363 1563465 2387030 3502620 2954208 +V5 2184963 2374515 1974647 2313226 1782744 1860757 +V6 5262172 6365930 5010369 9109487 6410977 6378638 +V7 2232587 2745906 2200995 3832216 2708070 2869295 +V8 483320 660332 433486 1062013 677822 748514 +V9 112905 136174 123604 162138 240686 195271 +V10 179154 195001 180519 98623 132470 123032 +V11 175220 169515 158401 111215 103539 159727 +V12 46503 55313 76310 46932 92318 43629 +V13 113796 91557 95960 92685 140973 112898 +V14 540798 596737 511783 876548 1626199 1385367 +V15 140806 135469 145016 229518 434119 398941 +V16 1334798 1318651 1308783 2345055 4068874 3565724 +V17 1083792 1145232 916864 838363 1678307 1304234 +V18 91671 101007 79999 85402 146939 126314 +V19 274181 282331 292645 394175 330817 293481 +V20 879658 809068 903330 1273966 959314 938277 +V21 608434 662366 727426 920178 1106194 1201520 +V22 1600960 1545158 1608816 1880288 2246189 2069613 +V23 2171614 2239769 2106004 2565354 4913676 4072322 +V24 4045143 3862213 4053630 7352540 5574415 6185035 +V25 202805 182042 165499 57267 86611 89320 +V26 586997 667911 522193 748212 595063 659353 +V27 229790 256287 253497 1189248 1025521 746948 +V28 1644853 1759382 1760494 3379214 4572430 4386799 +V29 8491372 9275641 8655578 12105700 13265172 13484917 +V30 724039 730730 640992 1475658 1191085 1213210 +V31 86524840 89500400 88593487 183705591 150949959 169189091 +V32 26916143 30167854 28256416 39049936 45546213 47237473 +V33 2683733 2654918 2386486 4786536 3622659 3879731 +V34 3919797 4529379 3595989 7965534 5963667 6339219 +V35 84384696 90691983 83322980 51888441 86013709 79735533 +V36 95751916 101056674 92760886 129551865 109580811 118980909 +V37 374328 416298 355931 255675 371223 338701 +V38 2219529 2333885 2206832 903780 981633 1136522 diff -r 000000000000 -r ad06aeed02c9 tests/exa2/dataMatrix.tsv --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/tests/exa2/dataMatrix.tsv Tue Aug 02 06:26:41 2016 -0400 @@ -0,0 +1,117 @@ +dataMatrix S1 S2 S3 S4 S5 S6 S7 S8 S9 S10 S11 S12 S13 S14 S15 S16 S17 S18 S19 S20 S21 S22 S23 S24 S25 S26 S27 S28 +V1 1484.78 1106.3 1217.84 1441.38 1213.63 1302.49 1412.79 1322.28 1258.89 1365.49 1146.78 1243 1242.47 1250.61 1307.52 1423.59 1290.51 1126.64 1421.23 1235.75 1084.56 1252.87 1254.74 1584.64 1474.43 1283.85 1347.74 1557.35 +V2 0 0 0 13.14 0 0 0 16.36 0 0 11.8 0 0 0 0 12.34 12.45 0 0 6.87 6.41 0 15.53 12.87 0 14.58 0 0 +V3 0 5.93 7.82 16.41 7.58 9.54 8.25 20.52 5.89 6.27 20.86 5.2 8.97 10.93 6.51 21.06 25.05 0 0 11.79 16.97 7.23 19.58 20.56 11.07 20.87 0 6.18 +V4 10.86 12.56 7.93 14.32 10.64 11.38 8.24 15.8 11.75 11.29 12 6.34 8.05 16.12 13.33 18.81 24.44 8.26 6.99 9.76 10.29 9.11 19.32 26.55 15.58 17.38 3.31 7.2 +V5 9.49 5.72 6.96 5.48 6.38 9.57 6.31 8.67 8.21 9.1 9.23 9.68 7.1 6.89 4.39 7.98 11.58 7.71 10.99 8.67 13.18 7.19 10.96 5.86 7.98 10.39 4.69 11.78 +V6 43.5 19.95 34.96 31.98 31.27 49.9 38.17 26.44 27.19 40.64 40.9 47 26.26 30.31 20.64 49.54 49.06 26.73 64.56 43.29 80.61 38.08 42.01 37.22 26.37 25.97 25.2 41.05 +V7 333.79 311.77 321.24 391.51 297.03 263.85 246.39 221.76 447.49 418.79 300.37 414.43 262.68 244.09 213.24 423.97 523.16 344.76 413.98 402.45 251.38 225.47 300.48 230.58 301.51 246.9 361.04 375.51 +V8 49.48 20.81 27.33 17.44 15.39 14.84 17.67 13.41 29.27 63.13 34.04 23.41 25.16 16.2 11.68 42.53 31.46 12.83 38.02 40.28 25.77 12.44 41.05 15.25 23.21 27.11 25.98 22.33 +V9 2.56 1.18 1.07 1.39 2.59 2.53 1.98 3.84 1.61 1.72 1.76 1.73 0.63 2.13 2.02 2.44 0 1.24 1.22 1.87 7.83 4.15 5.88 4.77 5.77 7.81 0 1.67 +V10 6.37 4.55 2.63 5.09 6.29 6.32 6.31 6.61 4.35 5.98 4.79 6.3 1.24 6.98 5.09 6.64 7.21 3.63 4.14 5.47 19.45 8.4 9.41 10.83 10.78 11.98 1.29 3.86 +V11 11.9 21.21 10.67 19.08 17.84 10.64 13.61 10.41 17.75 17.87 13.24 15.27 7.83 18.66 13.5 18.67 26.37 14.46 13.18 18.29 26.21 10.65 16.46 21.52 19.57 17.89 8.81 10.4 +V12 4.38 8.56 4.95 8.83 5.87 3.53 5.15 0.45 7.67 5.85 5.32 4.88 4.55 5.87 5.12 6.16 10.97 6.67 4.69 6.11 7.33 3.34 5.44 8.94 5.83 5.07 5.77 3.8 +V13 0.78 1.17 0.61 1.21 0.89 0 0.56 0.45 1.04 1.03 0 0.71 0.62 0.78 0 1.25 0 0.63 1.1 1.16 1.13 0 0.87 1.05 1.06 0.63 0.36 0.82 +V14 1511.11 1158.59 1529.32 1471.39 1654.17 2320.94 2630.11 2148.49 1248.21 1590.03 1120.83 1388.4 1523.12 2293.02 0 1566.36 1543.42 842.31 1421.66 1850.9 2870.84 2338.83 1979.28 3581.78 1757.49 2983.66 2967.62 1392.97 +V15 638.35 560.78 803.6 597.71 719.25 805.09 773.49 777.4 566.6 780.02 607.71 493.24 655.73 880.88 0 768.64 625.98 451.52 443.79 745.64 692.9 839.58 727.49 1376.26 622.72 1421.07 997.77 827.06 +V16 165.37 51.55 130.59 57.95 98.46 310.56 233.32 147.43 39.69 109.04 0 101.57 0 97.94 0 107.15 90.92 0 177.32 137.54 432.77 267.66 128.29 331.03 144.05 118.52 162.61 64.33 +V17 1586.23 2103.69 1926.52 1614.01 2166.04 2284.19 2506.01 2040.02 1327.06 1705.97 1461.31 1649.21 1759.17 2442.95 0 1875.52 1881.42 1512.88 1520.67 1981.82 3021.6 2389.78 2088.67 4697.26 1646.11 3269.32 2805.59 2315.4 +V18 243.32 227.33 349.71 195.5 327.78 307.89 703.12 197.9 0 234.07 330.09 246.26 256.2 419.19 0 265.17 192.4 188.52 255.13 481.91 462.41 216.66 336.29 478.85 152.09 424.2 257.62 198.53 +V19 1921.6 2015.61 2872.21 2975.67 2406.07 2438.08 2381.42 2789.98 2881.8 2119.69 1953.23 1880.63 1985.58 1819.19 0 2343.84 2473.67 1909.11 1798.62 2824.34 1735 2429.73 1958.41 4299.39 2609.31 3374.62 2824.95 3079.01 +V20 539.06 432.85 724.98 347.76 380.87 522.5 444.07 550.04 502.86 576.95 744.34 410.58 415.64 321.36 0 805.68 451.18 292.67 471.68 793.63 804.05 679.41 0 1047.85 444.04 444.5 547.87 738.82 +V21 288.7 0 0 0 0 0 0 0 0 144.5 0 0 0 154.85 0 119.48 0 0 0 0 0 0 0 179.2 0 208.44 0 0 +V22 273.95 149.66 287.92 0 327.34 0 717.56 0 0 311.8 0 121.95 0 172.76 0 238.66 161.38 0 0 0 0 0 608.86 398.84 173.3 462.34 347.64 312.02 +V23 614.701 98.849 0 217.085 320.044 246.769 107.187 114.252 185.453 0 0 179.589 0 0 0 169.996 58.781 133.231 209.81 106.94 159.654 97.758 160.071 0 131.035 0 169.996 0 +V24 7.329 7.035 6.437 5.973 6.656 0 0 6.663 7.697 7.511 6.876 7.531 6.817 6.579 5.978 0 7.191 7.57 6.105 6.994 6.84 0 0 0 7.322 7.182 0 5.935 +V25 28.846 26.604 26.246 0 25.943 0 24.929 0 29.452 27.652 28.324 28.299 0 0 24.957 0 28.278 28.029 25.955 27.292 27.437 24.795 0 0 0 26.468 0 0 +V26 16.71 15.574 15.343 0 0 14.629 0 16.021 18.624 16.703 16.82 15.859 15.086 14.725 14.543 0 16.698 16.782 14.461 16.186 16.36 0 0 14.682 0 14.853 0 14.503 +V27 187.78 134.86 104.51 164.53 145.23 101.57 194.53 143.99 147.12 34.35 110 105.84 95.85 160.24 97.8 108.21 112.99 23.83 110.36 146.6 127.22 132.54 134.6 123.13 156.39 138.56 133.67 14.17 +V28 20.22 14.96 11.79 17.94 16.79 11.55 22.08 17.8 16.64 3.74 13.56 12.82 11.43 19.05 11.62 12.97 13.58 2.8 13.44 17.3 15.87 14.87 16.1 14.06 16.01 17.45 15.64 1.43 +V29 75.78 77.98 38.21 69.93 86.6 35.94 93.92 70.68 68.63 21.05 45.99 55.4 45.65 58.75 39.82 34.02 46.6 9.28 29.73 65.55 65.73 62.13 56.75 35.83 61.46 60.77 54.74 13.94 +V30 12.75 14.38 8.06 13.79 15.45 7.33 16.09 14.9 12.84 3.34 8.78 11.42 9.47 12.32 7.87 7.82 9.61 1.87 8.15 11.43 13.59 8.63 11.36 8.74 10.62 15.01 10.94 2.45 +V31 152.24 143.82 99.08 127.98 140.79 77.54 137.85 112.09 123.92 25.64 107.74 112.76 89.79 107.46 71.99 82.81 95.43 16.35 78.04 79.82 132.59 126.74 133.86 82.86 109.23 124.44 108.45 24.55 +V32 938.99 725.51 504.85 599.76 701.02 393.83 668.81 533.32 633.26 165.95 562.51 557.52 415.33 598.74 338.85 352.62 470.93 115.55 385.39 327.2 589.46 648.36 743.1 360.36 591.98 574.85 527.59 150.99 +V33 2988.64 2781 2451.36 2290.88 2497.75 1772.76 2434.42 2222.88 2429.96 365.39 2071.07 2358.74 1919.88 2141.82 1236.79 1292.48 1836.8 465.52 1668.16 1167.73 2095.17 3286.45 2900.66 1323.11 2346.08 2245.29 2129.08 735.12 +V34 1644.27 1378.93 970.38 1310.7 1277.11 838.94 1276.17 1038.97 1216.93 256.38 1070.93 1248.62 908.78 1301.31 795.45 690.35 1002.58 246.43 1039.85 738.11 1609.77 1444.48 1417.84 843.04 1359.28 1512.42 1245.6 326.87 +V35 34.28 28.91 29.9 31.11 38.88 17.48 39.24 23.23 30.38 7.43 19.24 32.68 22.86 29.83 13.98 13.69 22.05 7.96 21.14 30.86 25.14 34.58 29.31 14.04 32.27 29.3 27.08 6.72 +V36 34.69 25.94 25.12 31.06 34.84 18.45 27.52 20.78 27.3 6.01 16.27 32.31 21.57 24.55 15.88 13.34 20.65 7.03 16.83 25.77 27.02 38.17 26.83 15.03 36.42 32.65 27.34 8.39 +V37 53.33 33.39 38.28 56 18.46 33.81 39.24 25.03 37.19 12.79 19.02 29.64 29.32 36.33 21.06 26.69 27.01 6.3 24.3 49.3 23.38 133.19 49.05 20.55 57.23 32.46 48.68 36.85 +V38 55.46 32.06 38.14 73.93 17.66 27.63 40.29 24.64 38.73 18.25 17.06 30.63 28.54 39.35 15.18 27.94 26.45 9.01 22.52 62.43 17.96 222 42.3 16.94 65.81 35.65 60.7 67.84 +V39 1615.79 832.94 948.85 1163.14 780.73 932.8 827.92 651.39 969.19 300.59 651.84 688.09 704.96 886.23 511.33 657.76 683.37 120.74 872.17 1307.25 802.54 2032.41 1544.2 758.36 1356.28 1432.05 1263.16 435.85 +V40 1699.27 766.05 997.32 1114.23 990.02 987.62 890.66 680.92 1015.76 309.1 716.86 590.9 623.14 866.72 485.55 674.31 659.58 128.63 766 948.5 764.57 1414.08 1579.67 769.54 1269.34 1677.86 1148.7 383.33 +V41 3995.34 1888.42 2393.66 1835.16 1684.97 1796.85 1192.55 1091.08 1984.75 909.69 1763.01 1285.69 1150.88 1126.86 1048.41 1193.59 1261.41 257.87 1437.84 1248.8 1395.5 2019.26 3393.17 1548.47 2189.84 2792.08 2003.12 761.04 +V42 6200.76 2703.73 3569.72 2967.38 2647.22 2701.52 1896.29 1731.65 3052.28 1397.8 2729.69 1770.64 1689.06 1813.5 1552.25 1977.75 1922.15 419.79 2262.29 1830.99 2226.75 2961.28 5042.17 2440.05 3329.37 4602.08 3086.87 1171.63 +V43 2766.76 1286.7 1535.67 1776.16 1043.65 1253.94 1165.85 989.89 1477.33 581.17 1081.96 962.62 1015.15 1217.68 877.56 1123.53 1046.42 120.87 1150.86 1405.41 1211.44 2590.33 1996.95 1466.31 2124.7 2561.89 1813.49 583.43 +V44 1808.56 1052.58 1064.38 1465.2 861.99 1062.52 1290.66 962.53 1196.05 311.32 811.08 1038.58 980.55 1253.84 820.41 794.37 949.8 179.67 766.54 1582.99 1107.43 3061.94 1384.89 1171.4 1849.11 2223.83 1643.52 731.04 +V45 361.49 289.55 263.82 424.39 250.66 201.69 240.88 240.95 284.18 73.44 248.27 273.46 216.48 217.64 165.11 174.49 215.91 41.61 227.97 327.36 274.12 615.76 379.63 251.66 345.47 506.13 366.01 133.46 +V46 2607.82 2000.16 1671.95 2357.94 1683.26 1571.32 1935.52 1840.49 1958.56 359.59 1995.27 1867.04 1691.03 1610.68 1121.25 1356.18 1606.91 323.82 1288.12 2384.86 1957.6 4620.77 2142.9 2097.88 2778.2 3638.56 2613.61 1057.86 +V47 4306.74 3278.54 2766.81 3676.12 2584.89 2707.8 3218.81 3013.78 3194.19 573.31 3189.42 3307.49 2902.72 2845.79 2162.9 2270.99 2779.88 470.14 2005.07 3846.66 3287.96 7678.68 3441.2 3648.6 4534.31 6234.27 4334.59 1807.15 +V48 2757.36 1972.09 1921.97 2047.43 2307.53 3450.36 2481.9 3192.32 2516.37 573.41 1605.23 4187.86 1340.3 2548.83 2241.75 1147.41 2178.56 1120.09 946.32 1988.3 3012.52 4348.05 4947.77 2894.49 2605.46 6227.79 3371.34 1704.39 +V49 2846.27 2112.17 2074.85 2484.04 2030.38 2892.38 2323.34 2689.36 2431.6 349.58 1659.98 3637.59 1615.48 2586.62 2360.5 1413.49 2212.28 835.81 1208.92 2272.05 2841.18 5130.58 4188 2879.36 2853.44 5754.18 3390.96 1517.17 +V50 63.24 68.39 44.94 64.93 37.36 31.18 60.74 35.49 50.78 15.1 52.13 43.34 53.45 55.07 31.66 31.25 44.48 10.88 33.05 60.72 34.37 209.37 55.71 37.41 51.12 69.22 68.87 58.26 +V51 1745.37 1185.09 1129.87 1082.42 1354.59 1492.4 1089.89 1391.1 1308.84 232.89 1028.07 1955.9 729.97 1004.49 961.76 574.74 1042.49 481.45 420.8 926.39 1134.46 2690.76 2585.95 984.56 1268.87 2558.63 1571.3 896.32 +V52 2325.89 1572.13 1488.2 1298.49 1823.74 2252.49 1456.85 2073.13 1786.37 391.59 1356.24 2938.31 868.29 1287.9 1431.16 730.25 1435.36 788.12 531.96 1115.79 1682.73 2924.65 3710.59 1520.02 1620.38 3734.6 2105.09 1202.01 +V53 352.51 261.05 248.74 309.45 289.73 416.53 266.85 428.71 321.69 70.28 236.94 537.25 193.5 326 319.28 189.21 300.36 130.33 152.84 203.76 442.22 511.73 516.04 437.43 331.36 880.17 434.44 225.04 +V54 216.14 119.32 400.57 336.36 56.47 89.37 155.36 49.48 177.88 130.48 97.22 114.95 135.48 117.64 76.58 160.44 117.05 29.18 83.99 83.8 18.56 195.87 181.22 21.21 196.54 152.66 116.73 74.64 +V55 3354.74 1889.02 3463.96 2595.51 1095.04 1188.43 1840.09 983.93 2051.34 989.95 1188.04 1824.94 1599.03 1844.36 1384.25 1654.65 1582.54 256.02 1244.41 1674.07 559.55 2535.71 2199.75 710.19 2034.19 3209.59 1770.93 909.24 +V56 689.37 323.77 632.5 615.72 142.49 199.66 291.67 166.84 382.75 226.87 180.91 296.75 246.47 305.63 207.47 338.53 262.63 61.25 203.85 288.31 71.53 584.03 353.14 107.89 389.42 519.26 314.68 183.74 +V57 6414.27 4067.65 4605.44 4227.56 3397.35 4016.57 3910.51 3544.13 4272.94 943.77 3394.68 4289.36 3906.95 4409.8 3951.68 4184.76 4022.87 363.34 3950.15 6095.62 3268.86 5116.94 4149.28 5007.15 4429.98 9674.53 5211.56 1994.81 +V58 6266.36 3952.06 4638.28 5920.74 2062.48 2497.54 4169.02 3215.66 4090.27 1503.58 1974.3 2964.15 3022.96 3735.08 2495.87 3708.52 2983.48 685.38 2577.02 5480.39 1887.75 9838.32 2801.7 2511.25 3945.65 6713.94 4469.5 2726.1 +V59 2080.03 874.53 1695.81 1374.04 1394.91 765.07 1135.71 1004.63 1290.59 440.83 1819.62 1091.7 968.82 881.98 936.64 1111.28 1135.01 347.02 942.22 791.46 436.14 1258.84 1124.31 632.85 885.87 2287.78 1044.93 565.34 +V60 4019.07 2882.43 2920.72 2773.03 2331.94 2583.34 2238.8 2947.54 2837.11 547.71 2278.86 2457.49 2253.88 2589.84 2426.05 2732.92 2456.51 183.15 2860.57 3738.87 2620.94 4076.27 2372.31 3116.74 2923.46 6850.52 3569.96 1439.67 +V61 30316.42 25360.24 24223.65 23154.87 18133.87 22307.77 23062.85 23590.21 23768.74 3389.17 15197.09 21838.91 19822.74 25644.43 20471.11 22104.93 20846.53 3426.18 25946.74 31472.14 23168.38 33432.4 20220.09 23962.44 22402.54 56752.04 29669.59 11842.22 +V62 62402.87 35366.22 42321.8 31258.28 45712.77 37769.84 37522.2 43278.66 41954.08 9480.21 43459.12 35791.78 33007.49 37555.87 30867.86 39466.54 36691.44 4528.68 42271.25 38040.41 33835.98 31348.66 36815.48 42979.08 35687.18 100505.6 45185.45 22694.47 +V63 5345.95 2464.9 3091.4 2805.39 3415.52 2539.93 3108.55 3202.34 3246.75 909.16 3585.55 2965.11 2611.3 2390.26 2831.05 3065.67 2908.16 412.12 2899.18 2910.75 2276.04 2502.17 3031.16 2991.49 2581.47 8752.35 3493.07 2141.79 +V64 5292.96 4008.72 4012.44 3886.04 3647.09 4488.47 3153.78 4115.83 4075.66 624.71 3329.53 3032.83 2312.02 3514.26 3087.36 3808.11 3180.69 512.3 5079.61 5010.13 3983.6 3431.06 4013.46 4214.52 3237.19 10957.47 4990.88 2498.27 +V65 25444.34 13558.49 16493.22 12642.32 18907.52 18009.06 14231.51 18620.1 17238.32 4086.37 19094.31 14715.79 12230.13 14978.12 11587.05 17803.28 15068.11 2966.33 20658.33 15965.36 15559.69 10040.91 15401.79 19709.15 13056.25 46168.25 19569.97 11265.33 +V66 13899.53 8944.63 10159.96 11074.5 10592.6 8214.08 10176.94 9842.82 10363.13 1692.08 10224.02 8347.23 9132.47 9222.4 7107.34 10746.74 9130.03 1305.62 12811.74 12563.23 8865.71 12920.36 8100.75 11165.92 10182.24 27260.68 12983.83 6047.39 +V67 23512.63 13724.09 15652.33 13277.44 14818.7 9962.66 15178.26 16531.8 15332.24 3861.68 16746.25 14037.72 17098.1 13131.82 11032.59 15239.5 14547.66 2299.46 12753.96 18982.74 12462.65 21193.96 9974.96 15787.58 16677.68 36925.01 18094.82 8438.68 +V68 821.85 585.07 674.53 840.2 718.19 574.86 651.98 653.13 689.98 98.6 706.95 560.39 503.06 591.94 388.25 697.71 574.72 120.85 1200.77 898.01 617.64 580.33 598.67 661.06 518.03 1915.59 873.76 476.91 +V69 5665.21 3978.35 4089.75 6323.17 5026.21 3349.48 4344.41 4708.65 4685.65 964.71 5080.09 3035.72 3840.01 3568.7 2368.7 4560.78 3742.33 988.46 7508.69 6081.63 3875.94 4956.96 3618.8 4029.91 4201.27 11407.44 5710.08 2652.15 +V70 22886.12 12566.47 13528.14 14763.84 14470.03 10368.79 13211.34 16198.81 14749.19 3707.08 18464.21 12968.59 14976.46 11752.16 9218.14 15570.81 13825.06 3229.53 15895.44 17072.56 12786.98 16896.42 8923.53 16188.56 14585.89 34726.7 17134.51 7604.44 +V71 11423.67 7260.23 8970.27 7850.77 7000.97 7015.29 6913.61 7283.92 7964.84 1553.03 6763.98 8126.89 6577.43 7492.23 8528.18 8010.27 7583.16 782.55 8054.41 8188.51 6660.61 8871.33 7225.66 8376.3 7110.27 20520.68 9375.97 4562.98 +V72 15637.27 10686.69 12884.29 7658.22 11941.71 16143.55 12067.08 13664.64 12585.43 2720.13 8240.99 12552.56 6342.23 11346.03 11072.08 8526.86 9680.13 2345.48 10280.75 9082.97 11453.12 8256.47 14972.26 12789.22 8817.57 34220.75 13734.14 8577.94 +V73 135.27 87.47 100.36 112.7 84.8 79.57 89.6 87.62 97.17 18.55 90.81 70.86 83.71 83.59 71.35 94.23 82.42 9.69 140.04 119.03 80.9 117.49 74.17 97.09 93.08 275.42 124.65 64.66 +V74 14754.19 9880.17 10295.05 8265.04 9657.1 14237.48 10965.97 14015.39 11508.8 2467.86 7500.76 12549.98 5789.86 8750.01 8146.62 7193.56 8321.8 2299.97 8467.08 8028.29 8820.04 6808.25 13820.28 11066.16 7654.05 27388.57 11506.59 6795.54 +V75 5044.67 4123.9 3380.68 3943.65 4810.8 3194.4 5781.71 4796.76 4384.57 880.42 3954.38 4991.5 3876.63 4266.2 4298.95 3072.12 4076.63 630.29 4034.2 4324.63 2909.16 3440.2 4620.79 2600.36 4008.27 5293.72 3903.92 890.76 +V76 27989.88 27031.11 27818.36 26202.32 31496.87 31500.9 29211.25 33237.97 29311.08 2502.57 30111.45 28276.59 27232.92 31880.59 26296.06 28183.17 28663.46 2023.76 31918.73 34538.92 29086.99 27914.54 27498.1 39484.04 33320.98 43351.62 33389.24 5645.12 +V77 6033.59 5638.84 5757.39 5676.17 6856.34 6971.39 5687.13 8714.58 6416.93 1072.27 6824.08 6173.48 5757.01 6766.91 5862.96 6737.69 6353.69 483.48 7038.06 7289.71 6550.93 6474.58 6456.35 8406.92 5959.81 9192.51 7171.11 1101.49 +V78 7531.71 9766.33 7917.05 7066.02 12533.47 8597.12 10418.97 11146.66 9372.17 1920.47 9102.5 9784.31 7945.3 9496.2 8096.37 6447.88 8478.76 1239.67 6847.86 10800.66 8877.01 9466.25 7931.75 8909.79 9603.09 8932.52 8921.12 1169.52 +V79 3370.7 4671.45 3614.71 3446.79 5356.27 4618.38 4037.77 7068.76 4523.1 1239.4 4406.1 4263.32 3463.28 4600.41 3959.76 3752.84 4074.29 427.18 3553.62 5079.92 4848.24 4350.41 4002.13 5329.31 3919.06 4823.83 4488.31 627.07 +V80 2868.85 5047.99 6140.96 3806.85 7216.89 5022.46 5256.06 7169.93 5316.25 1519.33 6397.22 6182.99 4471.19 4996.46 5044.24 3879.66 5161.96 972.74 4630.92 5302.12 5241.23 6062.4 4313.43 6004.09 4748.38 3915.5 5027.26 767.88 +V81 1281.17 2380.08 2630.57 1937.7 2948.17 2691.06 2049.1 4141.95 2507.47 842.56 2926.15 2622.13 1919.88 2621.26 2455.64 2368.02 2485.52 336.42 2351.46 2619.77 3160.6 2527.13 2012.54 3985.57 2068.56 2219.55 2618.15 662.38 +V82 2146.74 3932.04 7069.54 3549.09 7827.98 6430.48 4776.82 6935.8 5333.56 2022.04 6914.18 5835.39 4308.74 5546.11 4125.61 3316.45 5007.75 1321.86 5274.98 6382.23 4334.58 7275.77 4046.02 6099.75 5484.72 2524.77 5177.85 1504.1 +V83 1907.68 3559.05 5257.18 3193.54 6000.27 5750.61 3999.64 7589.13 4657.14 1824.28 6055.9 5410.81 3697.01 5334.87 4176.24 3397.35 4678.7 1069.69 5656.93 5396.48 4561.55 5252.67 3739.43 5920.38 4914.96 2876.17 4789.82 1031.33 +V84 1563.87 3853.97 8432.18 3998.8 8762.48 7300.71 5457.68 7690.55 5882.53 2579.31 7568.64 6990.02 4975.96 6365.79 4614.85 3298.13 5635.56 1615.25 6009.26 8596.72 5386.72 9056.14 3895.21 8087.23 6738.97 2065.6 6229.48 2415.73 +V85 3302.09 7922.23 14839.62 8695.1 14895.67 16252.17 9849.17 16439.95 11524.5 4784.86 15467.28 13457.69 9570.14 14436.95 11137.53 7751.42 11970.17 2992.62 14886.11 19383.47 13977.26 15573.95 8041.42 19837.99 14672.95 5478.44 13981.45 4998.55 +V86 0 296.05 366.33 1166.3 169.79 130.5 910.02 161.2 400.02 414.37 118.7 194.08 229.06 300.62 98.91 317.51 209.81 90.62 117.23 575.01 90.37 827.4 371.26 112.71 288.72 0 297.84 283.19 +V87 4401.04 2934.89 3681.01 6152.67 2603.61 2332.57 5978.46 1842.04 3740.79 1638.59 2181.44 2571.46 2344.9 3162.33 1741.34 4144.96 2691.07 852.26 2984.39 3569.27 1848.09 3728.68 4482.7 3372.3 3045.7 5581.86 3576.62 1103.72 +V88 4420.06 1904.34 2745.79 4347.63 2944.8 1893.85 4677.78 1650.45 3073.09 1248.88 2285.76 1717.32 1691.2 1981.19 1265.7 3952.21 2148.9 946 1923.49 2689.61 1150.01 2382.48 3544.16 2397.09 2072.07 4295.69 2556.82 977.41 +V89 2025.01 1309.69 1534.02 1724.7 997.37 1112.13 1504.17 1062.01 1408.64 356.9 1060.36 1233.53 1053.84 1231.26 1037.81 1653.63 1211.74 234.19 1373.49 870.32 1061.5 971.79 1322.44 1953.7 1160.28 3600.17 1539.21 897.22 +V90 7867.46 4397.17 5500.73 6128.55 4480.76 4361.83 6223.22 3656.82 5327.07 1374.86 5401.66 4479.81 3795.24 4545.42 3955.3 6335.78 4752.2 958.89 5860.18 3637.58 3601.16 3030.4 5119.26 7934.1 3942.76 12438.43 5695.48 3154 +V91 15420.21 6374.06 8675.69 9187.97 9400.76 7612.14 11663.12 6741.51 9384.43 2960.52 10596.69 7079.71 6181.61 7096.04 6025.42 12463.24 8240.45 2652.77 9551.32 5992.62 5097.49 4421.58 9300.09 12959.02 6316.93 21213.88 9356.62 5563.45 +V92 6810.22 3429.58 4299.33 6127.84 4075.32 3344.66 5125.32 3028.74 4530.12 1375.11 4175.7 3140.88 3084.36 3031.18 2636.89 6669.27 3789.71 1500.91 3604.49 2605.3 2145.3 2993.63 4287.71 5353.81 3153.44 9144.78 4161.06 2250.33 +V93 0 354.36 350.3 379.16 287.08 292.88 444.09 303.69 301.44 132.41 207.65 392.54 274.35 267.83 257.3 382.95 297.1 74.08 238.86 145.6 268.33 189 452.98 351.16 243.21 1063.47 369.08 296.38 +V94 2856.36 2456.4 2540.2 3367.98 2179.99 1475.83 2299.58 2163.25 2417.45 552.18 1869.28 2155.91 1924.65 1709.17 1633.53 3130.02 2070.43 550.12 1852.97 935.78 2010.54 1819.26 2184.75 2451.9 1909.68 5332.67 2312.19 1296.17 +V95 24091.97 15443.29 15942.72 17970 12145.72 10870.02 14682.71 15930 15884.55 4008.56 13247.25 15454.42 13712.53 11623.37 9969.61 19752.29 13959.91 3398.12 9621.47 5782.84 11913.08 12015.65 12566.22 17116.78 13006.74 34928.36 14618.89 8804.83 +V96 60793.4 33382.53 33715.73 32764.43 24127.78 25432.17 29776.84 35260.09 34406.62 11394.51 28888.49 34024.7 31279.19 25136.41 21490.99 42646.24 30577.67 7389.9 16961.84 12299.55 24074.2 26183.98 25604.38 38438.79 28979.32 78126.8 31333.61 20446.85 +V97 17570.51 9240.64 9721.88 10284.94 6788.15 7088.16 9220.42 9323.72 9904.8 3334.56 7668.14 9513.44 7976.91 7000.53 6579.27 12453.69 8532 2170.52 4915.75 3693.18 6545.25 7271.72 7741.63 11272.66 8234.6 21625.05 8912.48 5612.76 +V98 0 149.15 135.65 144.37 124.09 117.76 110.31 127.3 113.58 47.7 128.4 127.61 126.27 136.02 105.67 160.41 130.73 17.73 118.88 107.55 121.9 120.41 133.07 129.53 119.35 0 106.34 43.64 +V99 314.71 233.89 257.32 290.71 136.54 131.91 212.71 151.12 216.11 70.67 144.84 161.98 199.1 177.26 109.83 276.15 178.19 56.71 136.06 92.56 133.57 240.27 196.46 181.17 175.41 0 144.44 73.62 +V100 1063.57 888.31 802.4 899.21 524.53 465.73 990.79 508.3 767.86 235.42 425.38 531.11 631.35 755.31 380.35 795.06 586.43 170.6 399.27 323.3 426.24 771.87 698.1 557.47 570.57 1826.56 696.67 480.86 +V101 2587.9 1673.54 1654.1 1984.41 1404.72 1474.72 2767.56 1490.35 1879.66 525.82 725.28 1591.13 1128.98 1962.5 1210.7 1571.45 1365.01 433.48 897.88 885.71 1024.88 1264.44 2472.8 1515.25 1349.88 4852 1782.85 1340.9 +V102 3565.72 1975.42 2013.22 2140.6 1668.46 2455.07 3602.33 2361.46 2472.79 726.93 769.9 2420.79 1099.54 1908.1 1814.65 1765.41 1629.73 596.03 990.98 1185.95 1435.53 1123.37 4179.54 2564.22 1660.72 6490.51 2453.85 1944.54 +V103 0 48.29 0 0 0 0 70.19 0 14.81 28.04 0 0 0 0 0 0 0 0 0 123.9 0 0 0 0 0 5.93 16.23 43.56 +V104 0 123.49 65.51 80.81 98.52 68.99 195.36 83.25 89.49 55.5 97.05 128.29 99.81 113.05 120.62 0 93.14 47.16 119.68 367.75 78.17 59.42 81.7 79.25 121.63 0 113.45 109.53 +V105 0 85.23 0 0 0 0 168.05 0 31.66 62.66 0 0 0 0 0 0 0 0 0 233.87 0 0 0 0 0 0 29.23 82.69 +V106 0 183.94 76.89 113 125.6 0 370.73 0 108.77 125.97 150.38 121.92 135.84 186.45 103.87 0 116.41 63.52 154.21 496.94 107.83 94.48 106.85 0 141.87 0 137.77 156.29 +V107 423.7 0 164.21 507.86 578.77 522.85 0 346.55 317.99 234.19 0 299.3 343.68 661.93 499.17 759.59 427.28 274.44 363.88 432.47 486.04 383.04 381.67 0 497.37 0 318.06 202.18 +V108 4.6 2.76 2.42 3.59 3.85 3.27 5.32 4.47 3.79 0.98 4.96 3.56 3.84 4.62 5.72 5.58 4.72 0.89 3.99 4.66 4.99 4.79 4.25 2.82 3.33 4.09 4.11 0.74 +V109 1.46 1.14 1.27 1.13 1.52 1.57 1.35 1.14 1.32 0.18 1.18 1.28 1.13 1.2 1.14 1.63 1.26 0.19 1.32 0.9 1.14 1.6 1.07 1.42 1.87 0.91 1.28 0.34 +V110 0.52 0.55 0 0.49 0 0 0 0.51 0.26 0.28 0.35 0.38 0.56 0.44 0 0.55 0.38 0.2 0.32 0.37 0.35 0.52 0 0.44 0.44 0.28 0.34 0.16 +V111 0.4 0 0 0.43 0.32 0 0 0.39 0.19 0.21 0.3 0.37 0 0.4 0 0.42 0.25 0.2 0 0.36 0.25 0.47 0 0.39 0.38 0 0.23 0.2 +V112 0.76 0.49 0.43 0.64 0.49 0.48 0.23 0.71 0.53 0.17 0.47 0.52 0.59 0.62 0.38 0.65 0.54 0.1 0.32 0.49 0.38 0.55 0.49 0.6 0.64 0.47 0.49 0.11 +V113 0.61 0.58 0.53 0.53 0.45 0.31 0.15 0.51 0.46 0.15 0.36 0.51 0.44 0.45 0.48 0.66 0.48 0.1 0.33 0.53 0.37 0.61 0.36 0.51 0.67 0.33 0.46 0.13 +V114 0 0 0 0 0.09 0 0 0.12 0.03 0.05 0 0.1 0 0 0 0 0.02 0.04 0 0 0.1 0 0.12 0.11 0 0 0.04 0.06 +V115 0 0 0 0 0 0 0 0.13 0.02 0.04 0 0.11 0 0 0 0 0.02 0.05 0 0 0 0 0.15 0.12 0 0 0.03 0.06 +V116 1.76 1.89 1.43 1.19 1.34 1.64 0 2.33 1.44 0.68 1.16 2.16 0 1.74 2.23 1.12 1.4 0.83 0 1.47 1.37 1.34 2.27 1.83 1.51 1.43 1.4 0.65 diff -r 000000000000 -r ad06aeed02c9 tests/exa2/sampleMetadata.tsv --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/tests/exa2/sampleMetadata.tsv Tue Aug 02 06:26:41 2016 -0400 @@ -0,0 +1,29 @@ +sampleMetadata meta1 +S1 A +S2 A +S3 A +S4 A +S5 A +S6 A +S7 A +S8 A +S9 B +S10 B +S11 B +S12 B +S13 B +S14 B +S15 B +S16 C +S17 C +S18 C +S19 C +S20 C +S21 C +S22 C +S23 C +S24 C +S25 BC +S26 AB +S27 BC +S28 AC diff -r 000000000000 -r ad06aeed02c9 tests/exa2/variableMetadata.tsv --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/tests/exa2/variableMetadata.tsv Tue Aug 02 06:26:41 2016 -0400 @@ -0,0 +1,117 @@ +variableMetadata meta2 +V1 ER +V2 GGG +V3 GGG +V4 GGG +V5 GGG +V6 CE +V7 CE +V8 CE +V9 TG +V10 TG +V11 TG +V12 TG +V13 TG +V14 AM +V15 AM +V16 AM +V17 AM +V18 AM +V19 AM +V20 AM +V21 AM +V22 AM +V23 AM +V24 AM +V25 AM +V26 AM +V27 AM +V28 AM +V29 AM +V30 AM +V31 AM +V32 ER +V33 ER +V34 ER +V35 ER +V36 ER +V37 CER +V38 CER +V39 CER +V40 CER +V41 CER +V42 CER +V43 CER +V44 CER +V45 CER +V46 CER +V47 PP +V48 PP +V49 PP +V50 PP +V51 PP +V52 PP +V53 PP +V54 PP +V55 PP +V56 PP +V57 PP +V58 PP +V59 PP +V60 PP +V61 PP +V62 PP +V63 PP +V64 CC +V65 CC +V66 CC +V67 CC +V68 CC +V69 CC +V70 CC +V71 CC +V72 CC +V73 CC +V74 CC +V75 CC +V76 CC +V77 CC +V78 CC +V79 CC +V80 CC +V81 CC +V82 CC +V83 CC +V84 CC +V85 SM +V86 SM +V87 SM +V88 SM +V89 SM +V90 SM +V91 SM +V92 SM +V93 SM +V94 SM +V95 SM +V96 PI +V97 PI +V98 PI +V99 PI +V100 PI +V101 PI +V102 PI +V103 PI +V104 PI +V105 PI +V106 PI +V107 NG +V108 NG +V109 NG +V110 SO +V111 SO +V112 SO +V113 SO +V114 SO +V115 SO +V116 SO diff -r 000000000000 -r ad06aeed02c9 tests/heatmap_runtests.R --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/tests/heatmap_runtests.R Tue Aug 02 06:26:41 2016 -0400 @@ -0,0 +1,105 @@ +#!/usr/bin/env Rscript + +## Package +##-------- + +library(RUnit) + +## Constants +##---------- + +testOutDirC <- "output" +argVc <- commandArgs(trailingOnly = FALSE) +scriptPathC <- sub("--file=", "", argVc[grep("--file=", argVc)]) + + +## Functions +##----------- + +## Reading tables (matrix or data frame) +readTableF <- function(fileC, typeC = c("matrix", "dataframe")[1]) { + + file.exists(fileC) || stop(paste0("No output file \"", fileC ,"\".")) + + switch(typeC, + matrix = return(t(as.matrix(read.table(file = fileC, + header = TRUE, + row.names = 1, + sep = "\t", + stringsAsFactors = FALSE)))), + dataframe = return(read.table(file = fileC, + header = TRUE, + row.names = 1, + sep = "\t", + stringsAsFactors = FALSE))) + +} + +## Call wrapper +wrapperCallF <- function(paramLs) { + + ## Set program path + wrapperPathC <- file.path(dirname(scriptPathC), "..", "heatmap_wrapper.R") + + ## Set arguments + argLs <- NULL + for (parC in names(paramLs)) + argLs <- c(argLs, parC, paramLs[[parC]]) + + ## Call + wrapperCallC <- paste(c(wrapperPathC, argLs), collapse = " ") + + if(.Platform$OS.type == "windows") + wrapperCallC <- paste("Rscript", wrapperCallC) + + wrapperCodeN <- system(wrapperCallC) + + if (wrapperCodeN != 0) + stop("Error when running heatmap_wrapper.R.") + + ## Get output + outLs <- list() + if ("dataMatrix_out" %in% names(paramLs)) + outLs[["datMN"]] <- readTableF(paramLs[["dataMatrix_out"]], "matrix") + if ("sampleMetadata_out" %in% names(paramLs)) + outLs[["samDF"]] <- readTableF(paramLs[["sampleMetadata_out"]], "dataframe") + if ("variableMetadata_out" %in% names(paramLs)) + outLs[["varDF"]] <- readTableF(paramLs[["variableMetadata_out"]], "dataframe") + if("information" %in% names(paramLs)) + outLs[["infVc"]] <- readLines(paramLs[["information"]]) + + return(outLs) +} + +## Setting default parameters +defaultArgF <- function(testInDirC) { + + defaultArgLs <- list() + if(file.exists(file.path(dirname(scriptPathC), testInDirC, "dataMatrix.tsv"))) + defaultArgLs[["dataMatrix_in"]] <- file.path(dirname(scriptPathC), testInDirC, "dataMatrix.tsv") + if(file.exists(file.path(dirname(scriptPathC), testInDirC, "sampleMetadata.tsv"))) + defaultArgLs[["sampleMetadata_in"]] <- file.path(dirname(scriptPathC), testInDirC, "sampleMetadata.tsv") + if(file.exists(file.path(dirname(scriptPathC), testInDirC, "variableMetadata.tsv"))) + defaultArgLs[["variableMetadata_in"]] <- file.path(dirname(scriptPathC), testInDirC, "variableMetadata.tsv") + + defaultArgLs[["dataMatrix_out"]] <- file.path(dirname(scriptPathC), testOutDirC, "dataMatrix.tsv") + defaultArgLs[["sampleMetadata_out"]] <- file.path(dirname(scriptPathC), testOutDirC, "sampleMetadata.tsv") + defaultArgLs[["variableMetadata_out"]] <- file.path(dirname(scriptPathC), testOutDirC, "variableMetadata.tsv") + defaultArgLs[["figure"]] <- file.path(dirname(scriptPathC), testOutDirC, "figure.pdf") + defaultArgLs[["information"]] <- file.path(dirname(scriptPathC), testOutDirC, "information.txt") + + defaultArgLs + +} + +## Main +##----- + +## Create output folder +file.exists(testOutDirC) || dir.create(testOutDirC) + +## Run tests +test.suite <- defineTestSuite('tests', dirname(scriptPathC), testFileRegexp = paste0('^.*_tests\\.R$'), testFuncRegexp = '^.*$') +isValidTestSuite(test.suite) +test.results <- runTestSuite(test.suite) +print(test.results) diff -r 000000000000 -r ad06aeed02c9 tests/heatmap_tests.R --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/tests/heatmap_tests.R Tue Aug 02 06:26:41 2016 -0400 @@ -0,0 +1,57 @@ +test_input_cut4 <- function() { + + testDirC <- "input" + argLs <- list(disC = "1-cor", + cutSamN = "4", + cutVarN = "3", + corMetC = "spearman", + aggMetC = "ward", + colC = "blueOrangeRed", + scaL = "TRUE", + cexN = "0.8") + + argLs <- c(defaultArgF(testDirC), argLs) + outLs <- wrapperCallF(argLs) + + checkEqualsNumeric(outLs[['samDF']][13, 'heat_clust'], 4) + +} + +test_exa1_cut3 <- function() { + + testDirC <- "exa1" + argLs <- list(disC = "1-cor", + cutSamN = "3", + cutVarN = "4", + corMetC = "spearman", + aggMetC = "ward", + colC = "blueOrangeRed", + scaL = "TRUE", + cexN = "1") + + argLs <- c(defaultArgF(testDirC), argLs) + outLs <- wrapperCallF(argLs) + + checkEqualsNumeric(outLs[['varDF']]['V24', 'heat_clust'], 4) + +} + +test_exa2_cut4 <- function() { + + testDirC <- "exa2" + argLs <- list(disC = "1-cor", + cutSamN = "1", + cutVarN = "1", + corMetC = "spearman", + aggMetC = "ward", + colC = "blueOrangeRed", + scaL = "TRUE", + cexN = "1") + + argLs <- c(defaultArgF(testDirC), argLs) + outLs <- wrapperCallF(argLs) + + checkEquals(outLs[['varDF']]['V31', 'meta2'], 'AM') + +} + diff -r 000000000000 -r ad06aeed02c9 tests/input/dataMatrix.tsv --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/tests/input/dataMatrix.tsv Tue Aug 02 06:26:41 2016 -0400 @@ -0,0 +1,16 @@ +dataMatrix HU_017 HU_028 HU_034 HU_051 HU_060 HU_078 HU_091 HU_093 HU_099 HU_110 HU_130 HU_134 HU_138 HU_149 HU_152 HU_175 HU_178 HU_185 HU_204 HU_208 +HMDB03193 76043 412165 44943 27242 436566 173175 242549 57066 559869 3732 339188 471368 262271 127285 451270 212500 79673 NA 891129 43907 +HMDB01101 30689 6877586 52217 3158 10789748 229568 4763576 3878773 976436 831937 608298 1605075 72021 442510 1107705 1464339 31250 2724553 72900 32742 +HMDB10348 47259 544877 60885 34582 529874 168264 176500 76457 610110 16262 279156 524468 451573 591487 433529 161069 214392 13781 1580343 39315 +HMDB59717 357351 1030464 301983 67604 306862 1028110 1530493 270027 1378535 289677 808334 1132813 871209 895435 715190 1563158 784738 146195 994336 239030 +HMDB00822 483755 579287 1132413 157113 1577570 1469735 1085454 477909 814755 245417 610681 763706 2406336 827531 992508 569605 355321 150259 1334200 271010 +HMDB13189 2644620 727587 1661412 619181 136278 2755434 593863 837865 3526136 2003278 1608814 3446611 1941527 113937 3132404 2893445 2092753 1034666 1517319 841661 +HMDB00299 250551 1046138 456162 159386 1013302 808657 614370 250403 768004 242085 504108 1014041 1362408 1057660 1110050 566050 411886 142233 1992420 284775 +HMDB00191 560002 771533 575790 392284 888498 785428 645785 591569 960658 910201 639437 1092885 1409045 2292023 1246459 1945577 710519 773384 1061418 622898 +HMDB00518 34236 58249 85944 NA 342102 129886 175800 13154 230242 NA 440223 315368 10657 419508 48673 28361 514579 23108 867108 73831 +HMDB00715 1252089 2547452 905408 371059 4983588 5140022 2658555 814523 2558923 859466 4184204 3865723 3236644 2615560 3820724 3577833 2295288 625924 7517724 1341900 +HMDB01032 2569205 26023086 1604999 430453 8103558 26222916 257139 675754 59906109 263055 31151730 18648127 14989438 1554658 20249262 5588731 871010 15920 9120781 44276 +HMDB00208 747080 13420742 595872 1172376 7172632 3143654 4059767 1433702 5593888 5402629 2477288 3346077 4230072 7621236 8960828 10335722 7037373 1574738 3359238 2540044 +HMDB04824 374028 1144386 539206 178517 1046190 959381 605191 310260 1253319 477259 477995 825691 1157093 1089284 1411802 1020206 782673 346761 1824553 387811 +HMDB00512 53304 319783 280560 85009 1333877 556003 590779 209285 342532 198512 569970 525240 246282 1140422 542345 1171008 827723 222953 438839 85554 +HMDB00251 368600 616555 94936 622468 180988 293988 352855 767894 268331 167246 310918 1248919 577184 10985 335711 403815 80614 63393 454489 616061 diff -r 000000000000 -r ad06aeed02c9 tests/input/sampleMetadata.tsv --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/tests/input/sampleMetadata.tsv Tue Aug 02 06:26:41 2016 -0400 @@ -0,0 +1,21 @@ +sampleMetadata injectionOrder mode age bmi gender +HU_017 2 pos 41 23.03 M +HU_028 7 pos 41 23.92 F +HU_034 9 pos 52 23.37 M +HU_051 20 pos 24 23.23 F +HU_060 24 pos 55 28.72 F +HU_078 34 pos 46 25.18 M +HU_091 42 pos 61 26.12 M +HU_093 43 pos 53 21.71 M +HU_099 46 pos 23 21.3 M +HU_110 53 pos 50 20.9 F +HU_130 63 pos 33 26.06 M +HU_134 67 pos 48 22.89 M +HU_138 68 pos 42 21.88 M +HU_149 72 pos 35 19.49 F +HU_152 75 pos 26 17.58 F +HU_175 87 pos 35 21.26 F +HU_178 88 pos 60 32.87 F +HU_185 95 pos 42 21.09 F +HU_204 104 pos 31 29.06 M +HU_208 106 pos 27 18.61 F diff -r 000000000000 -r ad06aeed02c9 tests/input/variableMetadata.tsv --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/tests/input/variableMetadata.tsv Tue Aug 02 06:26:41 2016 -0400 @@ -0,0 +1,16 @@ +variableMetadata name +HMDB03193 Testosterone_glucuronide +HMDB01101 p-Anisic_acid +HMDB10348 Dehydroepiandrosterone_3-glucuronide +HMDB59717 Glu-Val +HMDB00822 p-Hydroxymandelic_acid +HMDB13189 3-Indole_carboxylic_acid_glucuronide +HMDB00299 Xanthosine +HMDB00191 L-Aspartic_acid +HMDB00518 Chenodeoxycholic_acid +HMDB00715 Kynurenic_acid +HMDB01032 Dehydroepiandrosterone_sulfate +HMDB00208 Oxoglutaric_acid +HMDB04824 N2,N2-Dimethylguanosine +HMDB00512 N-Acetyl-L-phenylalanine +HMDB00251 Taurine diff -r 000000000000 -r ad06aeed02c9 tests/output/dataMatrix.tsv --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/tests/output/dataMatrix.tsv Tue Aug 02 06:26:41 2016 -0400 @@ -0,0 +1,16 @@ +dataMatrix HU_051 HU_208 HU_178 HU_130 HU_175 HU_099 HU_152 HU_204 HU_017 HU_138 HU_034 HU_078 HU_060 HU_149 HU_028 HU_093 HU_134 HU_091 HU_110 HU_185 +HMDB13189 619181 841661 2092753 1608814 2893445 3526136 3132404 1517319 2644620 1941527 1661412 2755434 136278 113937 727587 837865 3446611 593863 2003278 1034666 +HMDB00251 622468 616061 80614 310918 403815 268331 335711 454489 368600 577184 94936 293988 180988 10985 616555 767894 1248919 352855 167246 63393 +HMDB01101 3158 32742 31250 608298 1464339 976436 1107705 72900 30689 72021 52217 229568 10789748 442510 6877586 3878773 1605075 4763576 831937 2724553 +HMDB00191 392284 622898 710519 639437 1945577 960658 1246459 1061418 560002 1409045 575790 785428 888498 2292023 771533 591569 1092885 645785 910201 773384 +HMDB00208 1172376 2540044 7037373 2477288 10335722 5593888 8960828 3359238 747080 4230072 595872 3143654 7172632 7621236 13420742 1433702 3346077 4059767 5402629 1574738 +HMDB59717 67604 239030 784738 808334 1563158 1378535 715190 994336 357351 871209 301983 1028110 306862 895435 1030464 270027 1132813 1530493 289677 146195 +HMDB00512 85009 85554 827723 569970 1171008 342532 542345 438839 53304 246282 280560 556003 1333877 1140422 319783 209285 525240 590779 198512 222953 +HMDB00518 NA 73831 514579 440223 28361 230242 48673 867108 34236 10657 85944 129886 342102 419508 58249 13154 315368 175800 NA 23108 +HMDB00822 157113 271010 355321 610681 569605 814755 992508 1334200 483755 2406336 1132413 1469735 1577570 827531 579287 477909 763706 1085454 245417 150259 +HMDB00715 371059 1341900 2295288 4184204 3577833 2558923 3820724 7517724 1252089 3236644 905408 5140022 4983588 2615560 2547452 814523 3865723 2658555 859466 625924 +HMDB01032 430453 44276 871010 31151730 5588731 59906109 20249262 9120781 2569205 14989438 1604999 26222916 8103558 1554658 26023086 675754 18648127 257139 263055 15920 +HMDB00299 159386 284775 411886 504108 566050 768004 1110050 1992420 250551 1362408 456162 808657 1013302 1057660 1046138 250403 1014041 614370 242085 142233 +HMDB04824 178517 387811 782673 477995 1020206 1253319 1411802 1824553 374028 1157093 539206 959381 1046190 1089284 1144386 310260 825691 605191 477259 346761 +HMDB03193 27242 43907 79673 339188 212500 559869 451270 891129 76043 262271 44943 173175 436566 127285 412165 57066 471368 242549 3732 NA +HMDB10348 34582 39315 214392 279156 161069 610110 433529 1580343 47259 451573 60885 168264 529874 591487 544877 76457 524468 176500 16262 13781 diff -r 000000000000 -r ad06aeed02c9 tests/output/essai.tsv --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/tests/output/essai.tsv Tue Aug 02 06:26:41 2016 -0400 @@ -0,0 +1,21 @@ +sampleMetadata injectionOrder mode age bmi gender heat_clust +HU_017 2 pos 41 23.03 M 1 +HU_034 9 pos 52 23.37 M 1 +HU_204 104 pos 31 29.06 M 2 +HU_134 67 pos 48 22.89 M 2 +HU_099 46 pos 23 21.3 M 2 +HU_078 34 pos 46 25.18 M 2 +HU_130 63 pos 33 26.06 M 2 +HU_028 7 pos 41 23.92 F 2 +HU_138 68 pos 42 21.88 M 2 +HU_152 75 pos 26 17.58 F 2 +HU_051 20 pos 24 23.23 F 3 +HU_208 106 pos 27 18.61 F 3 +HU_110 53 pos 50 20.9 F 3 +HU_178 88 pos 60 32.87 F 3 +HU_149 72 pos 35 19.49 F 3 +HU_175 87 pos 35 21.26 F 3 +HU_060 24 pos 55 28.72 F 4 +HU_091 42 pos 61 26.12 M 4 +HU_093 43 pos 53 21.71 M 4 +HU_185 95 pos 42 21.09 F 4 diff -r 000000000000 -r ad06aeed02c9 tests/output/figure.pdf Binary file tests/output/figure.pdf has changed diff -r 000000000000 -r ad06aeed02c9 tests/output/information.txt --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/tests/output/information.txt Tue Aug 02 06:26:41 2016 -0400 @@ -0,0 +1,24 @@ + +Start of the 'Heatmap' module: Tue 02 Aug 2016 11:48:22 AM + +Arguments used: + + value +dataMatrix_in "tests/input/dataMatrix.tsv" +sampleMetadata_in "tests/input/sampleMetadata.tsv" +variableMetadata_in "tests/input/variableMetadata.tsv" +dataMatrix_out "tests/output/dataMatrix.tsv" +sampleMetadata_out "tests/output/sampleMetadata.tsv" +variableMetadata_out "tests/output/variableMetadata.tsv" +figure "tests/output/figure.pdf" +information "tests/output/information.txt" +disC "1-cor" +cutSamN "4" +cutVarN "3" +corMetC "spearman" +aggMetC "ward" +colC "blueOrangeRed" +scaL "TRUE" +cexN "0.8" + +End of the 'Heatmap' Galaxy module call: Tue 02 Aug 2016 11:48:22 AM diff -r 000000000000 -r ad06aeed02c9 tests/output/sampleMetadata.tsv --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/tests/output/sampleMetadata.tsv Tue Aug 02 06:26:41 2016 -0400 @@ -0,0 +1,21 @@ +sampleMetadata injectionOrder mode age bmi gender heat_clust +HU_051 20 pos 24 23.23 F 3 +HU_208 106 pos 27 18.61 F 3 +HU_178 88 pos 60 32.87 F 1 +HU_130 63 pos 33 26.06 M 1 +HU_175 87 pos 35 21.26 F 1 +HU_099 46 pos 23 21.3 M 1 +HU_152 75 pos 26 17.58 F 1 +HU_204 104 pos 31 29.06 M 1 +HU_017 2 pos 41 23.03 M 1 +HU_138 68 pos 42 21.88 M 1 +HU_034 9 pos 52 23.37 M 1 +HU_078 34 pos 46 25.18 M 1 +HU_060 24 pos 55 28.72 F 4 +HU_149 72 pos 35 19.49 F 4 +HU_028 7 pos 41 23.92 F 2 +HU_093 43 pos 53 21.71 M 2 +HU_134 67 pos 48 22.89 M 2 +HU_091 42 pos 61 26.12 M 2 +HU_110 53 pos 50 20.9 F 2 +HU_185 95 pos 42 21.09 F 2 diff -r 000000000000 -r ad06aeed02c9 tests/output/variableMetadata.tsv --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/tests/output/variableMetadata.tsv Tue Aug 02 06:26:41 2016 -0400 @@ -0,0 +1,16 @@ +variableMetadata name heat_clust +HMDB13189 3-Indole_carboxylic_acid_glucuronide 3 +HMDB00251 Taurine 3 +HMDB01101 p-Anisic_acid 2 +HMDB00191 L-Aspartic_acid 2 +HMDB00208 Oxoglutaric_acid 2 +HMDB59717 Glu-Val 2 +HMDB00512 N-Acetyl-L-phenylalanine 2 +HMDB00518 Chenodeoxycholic_acid 1 +HMDB00822 p-Hydroxymandelic_acid 1 +HMDB00715 Kynurenic_acid 1 +HMDB01032 Dehydroepiandrosterone_sulfate 1 +HMDB00299 Xanthosine 1 +HMDB04824 N2,N2-Dimethylguanosine 1 +HMDB03193 Testosterone_glucuronide 1 +HMDB10348 Dehydroepiandrosterone_3-glucuronide 1