~ubuntu-branches/ubuntu/trusty/qiime/trusty

« back to all changes in this revision

Viewing changes to doc/scripts/print_metadata_stats.rst

  • Committer: Package Import Robot
  • Author(s): Andreas Tille
  • Date: 2013-06-17 18:28:26 UTC
  • mfrom: (9.1.2 sid)
  • Revision ID: package-import@ubuntu.com-20130617182826-376az5ad080a0sfe
Tags: 1.7.0+dfsg-1
Upload preparations done for BioLinux to Debian

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
.. _print_metadata_stats:
 
2
 
 
3
.. index:: print_metadata_stats.py
 
4
 
 
5
*print_metadata_stats.py* -- Count the number of samples associated to a category value
 
6
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
7
 
 
8
**Description:**
 
9
 
 
10
Sum up the number of samples with each category value and print this information.
 
11
 
 
12
 
 
13
**Usage:** :file:`print_metadata_stats.py [options]`
 
14
 
 
15
**Input Arguments:**
 
16
 
 
17
.. note::
 
18
 
 
19
        
 
20
        **[REQUIRED]**
 
21
                
 
22
        -m, `-`-mapping_file
 
23
                The input metadata file
 
24
        -c, `-`-category
 
25
                The category to examine
 
26
        
 
27
        **[OPTIONAL]**
 
28
                
 
29
        -o, `-`-output_fp
 
30
                Path where output will be written [default: print to screen]
 
31
 
 
32
 
 
33
**Output:**
 
34
 
 
35
Two columns, the first being the category value and the second being the count. Output is to standard out. If there are unspecified values, the output category is identified as ***UNSPECIFIED***
 
36
 
 
37
 
 
38
**Example:**
 
39
 
 
40
Count the number of samples associated with Treatment
 
41
 
 
42
::
 
43
 
 
44
        print_metadata_stats.py -m $PWD/mapping.txt -c Treatment
 
45
 
 
46
**Example writting the output to a file:**
 
47
 
 
48
Count the number of samples associated with Treatment and save them to a file called stats.txt
 
49
 
 
50
::
 
51
 
 
52
        print_metadata_stats.py -m mapping.txt -c Treatment -o stats.txt
 
53
 
 
54