Mercurial > repos > peterjc > count_roi_variants
annotate tools/count_roi_variants/README.rst @ 10:7a05cb080ea5 draft
planemo upload for repository https://github.com/peterjc/pico_galaxy/tree/master/tools/count_roi_variants commit 2c1cc3ac829140d469816ec5e9892f96624270bf-dirty
author | peterjc |
---|---|
date | Thu, 11 May 2017 12:43:27 -0400 |
parents | 7f6a56260be6 |
children | 2429bebcab13 |
rev | line source |
---|---|
0 | 1 Count sequence variants in region of interest in BAM file |
2 ========================================================= | |
3 | |
4 This tool is copyright 2016 by Peter Cock, The James Hutton Institute | |
5 (formerly SCRI, Scottish Crop Research Institute), UK. All rights reserved. | |
6 See the licence text below. | |
7 | |
8 This tool runs the command ``samtools view`` (taking advantage of an | |
9 indexed BAM file) to access only those reads mapped to the region of | |
10 interest (ROI), and then counts the different sequence variants found. | |
11 | |
12 Internally this tool uses the command-line samtools suite. | |
13 | |
14 This tool is available from the Galaxy Tool Shed at: | |
15 http://toolshed.g2.bx.psu.edu/view/peterjc/count_roi_variants | |
16 | |
17 | |
4
f7901a2a9d0c
v0.0.4 - Improved usage text and README for use outside of Galaxy.
peterjc
parents:
3
diff
changeset
|
18 Use outside of Galaxy |
f7901a2a9d0c
v0.0.4 - Improved usage text and README for use outside of Galaxy.
peterjc
parents:
3
diff
changeset
|
19 ===================== |
f7901a2a9d0c
v0.0.4 - Improved usage text and README for use outside of Galaxy.
peterjc
parents:
3
diff
changeset
|
20 |
f7901a2a9d0c
v0.0.4 - Improved usage text and README for use outside of Galaxy.
peterjc
parents:
3
diff
changeset
|
21 You just need the ``count_roi_variants.py`` script and to have samtools |
f7901a2a9d0c
v0.0.4 - Improved usage text and README for use outside of Galaxy.
peterjc
parents:
3
diff
changeset
|
22 on the ``$PATH``. If you move/copy the script somewhere on your ``$PATH`` |
f7901a2a9d0c
v0.0.4 - Improved usage text and README for use outside of Galaxy.
peterjc
parents:
3
diff
changeset
|
23 and then you can run it like this:: |
f7901a2a9d0c
v0.0.4 - Improved usage text and README for use outside of Galaxy.
peterjc
parents:
3
diff
changeset
|
24 |
f7901a2a9d0c
v0.0.4 - Improved usage text and README for use outside of Galaxy.
peterjc
parents:
3
diff
changeset
|
25 $ count_roi_variants.py --help |
f7901a2a9d0c
v0.0.4 - Improved usage text and README for use outside of Galaxy.
peterjc
parents:
3
diff
changeset
|
26 |
f7901a2a9d0c
v0.0.4 - Improved usage text and README for use outside of Galaxy.
peterjc
parents:
3
diff
changeset
|
27 Or, call the script at an explicit path:: |
f7901a2a9d0c
v0.0.4 - Improved usage text and README for use outside of Galaxy.
peterjc
parents:
3
diff
changeset
|
28 |
f7901a2a9d0c
v0.0.4 - Improved usage text and README for use outside of Galaxy.
peterjc
parents:
3
diff
changeset
|
29 $ /path/to/my/stuff/count_roi_variants.py --help |
f7901a2a9d0c
v0.0.4 - Improved usage text and README for use outside of Galaxy.
peterjc
parents:
3
diff
changeset
|
30 |
f7901a2a9d0c
v0.0.4 - Improved usage text and README for use outside of Galaxy.
peterjc
parents:
3
diff
changeset
|
31 Run like this it will use the current default Python. This was written and |
f7901a2a9d0c
v0.0.4 - Improved usage text and README for use outside of Galaxy.
peterjc
parents:
3
diff
changeset
|
32 tested under Python 2.7, but should also work under Python 2.6. e.g.:: |
f7901a2a9d0c
v0.0.4 - Improved usage text and README for use outside of Galaxy.
peterjc
parents:
3
diff
changeset
|
33 |
f7901a2a9d0c
v0.0.4 - Improved usage text and README for use outside of Galaxy.
peterjc
parents:
3
diff
changeset
|
34 $ python2.6 /path/to/my/stuff/count_roi_variants.py --help |
f7901a2a9d0c
v0.0.4 - Improved usage text and README for use outside of Galaxy.
peterjc
parents:
3
diff
changeset
|
35 |
f7901a2a9d0c
v0.0.4 - Improved usage text and README for use outside of Galaxy.
peterjc
parents:
3
diff
changeset
|
36 This does not yet support Python 3. |
f7901a2a9d0c
v0.0.4 - Improved usage text and README for use outside of Galaxy.
peterjc
parents:
3
diff
changeset
|
37 |
f7901a2a9d0c
v0.0.4 - Improved usage text and README for use outside of Galaxy.
peterjc
parents:
3
diff
changeset
|
38 The sample data and tests are designed to be run via Galaxy. |
f7901a2a9d0c
v0.0.4 - Improved usage text and README for use outside of Galaxy.
peterjc
parents:
3
diff
changeset
|
39 |
f7901a2a9d0c
v0.0.4 - Improved usage text and README for use outside of Galaxy.
peterjc
parents:
3
diff
changeset
|
40 |
f7901a2a9d0c
v0.0.4 - Improved usage text and README for use outside of Galaxy.
peterjc
parents:
3
diff
changeset
|
41 Automated Galaxy Installation |
f7901a2a9d0c
v0.0.4 - Improved usage text and README for use outside of Galaxy.
peterjc
parents:
3
diff
changeset
|
42 ============================= |
0 | 43 |
44 This should be straightforward, Galaxy should automatically download and install | |
45 samtools if required. | |
46 | |
47 | |
4
f7901a2a9d0c
v0.0.4 - Improved usage text and README for use outside of Galaxy.
peterjc
parents:
3
diff
changeset
|
48 Manual Galaxy Installation |
f7901a2a9d0c
v0.0.4 - Improved usage text and README for use outside of Galaxy.
peterjc
parents:
3
diff
changeset
|
49 ========================== |
0 | 50 |
51 This expects samtools to be on the ``$PATH``, and was tested using v0.1.3 | |
52 | |
53 To install the wrapper copy or move the following files under the Galaxy tools | |
54 folder, e.g. in a ``tools/count_roi_variants`` folder: | |
55 | |
56 * ``count_roi_variants.xml`` (the Galaxy tool definition) | |
57 * ``count_roi_variants.py`` (the Python wrapper script) | |
58 * ``README.rst`` (this file) | |
59 | |
60 You will also need to modify the ``tools_conf.xml`` file to tell Galaxy to offer | |
61 the tool. Just add the line, perhaps under the NGS tools section:: | |
62 | |
63 <tool file="count_roi_variants/count_roi_variants.xml" /> | |
64 | |
65 If you wish to run the unit tests, also move/copy the ``test-data/`` files | |
66 under Galaxy's ``test-data/`` folder. Then:: | |
67 | |
68 $ ./run_tests.sh -id count_roi_variants | |
69 | |
70 That's it. | |
71 | |
72 | |
73 History | |
74 ======= | |
75 | |
76 ======= ====================================================================== | |
77 Version Changes | |
78 ------- ---------------------------------------------------------------------- | |
79 v0.0.1 - Initial public release | |
1
16defe17fda9
v0.0.2 Cope with pipes in reference name (e.g. NCBI style FASTA naming)
peterjc
parents:
0
diff
changeset
|
80 v0.0.2 - Cope with pipes in reference name (e.g. NCBI style FASTA naming) |
3
7cd370b7a952
v0.0.3 - More tests, fixed accidental path change in v0.0.2
peterjc
parents:
2
diff
changeset
|
81 v0.0.3 - Include a functional test for using an unrecognised reference. |
4
f7901a2a9d0c
v0.0.4 - Improved usage text and README for use outside of Galaxy.
peterjc
parents:
3
diff
changeset
|
82 v0.0.4 - Improved usage text and README for use outside of Galaxy. |
10
7a05cb080ea5
planemo upload for repository https://github.com/peterjc/pico_galaxy/tree/master/tools/count_roi_variants commit 2c1cc3ac829140d469816ec5e9892f96624270bf-dirty
peterjc
parents:
8
diff
changeset
|
83 v0.0.5 - Fix samtools dependency version inconsistency, using v1.2 now. |
7a05cb080ea5
planemo upload for repository https://github.com/peterjc/pico_galaxy/tree/master/tools/count_roi_variants commit 2c1cc3ac829140d469816ec5e9892f96624270bf-dirty
peterjc
parents:
8
diff
changeset
|
84 - Use ``<command detect_errors="aggressive">`` (internal change only). |
7a05cb080ea5
planemo upload for repository https://github.com/peterjc/pico_galaxy/tree/master/tools/count_roi_variants commit 2c1cc3ac829140d469816ec5e9892f96624270bf-dirty
peterjc
parents:
8
diff
changeset
|
85 - Single quote command line arguments (internal change only). |
0 | 86 ======= ====================================================================== |
87 | |
88 | |
89 Developers | |
90 ========== | |
91 | |
92 Development is on this GitHub repository: | |
93 https://github.com/peterjc/pico_galaxy/tree/master/tools/count_roi_variants | |
94 | |
95 For pushing a release to the test or main "Galaxy Tool Shed", use the following | |
96 Planemo commands (which requires you have set your Tool Shed access details in | |
97 ``~/.planemo.yml`` and that you have access rights on the Tool Shed):: | |
98 | |
8
7f6a56260be6
planemo upload for repository https://github.com/peterjc/pico_galaxy/tree/master/tools/count_roi_variants commit 7f8f223933c405b821dbfee3edcd4f111633636a-dirty
peterjc
parents:
4
diff
changeset
|
99 $ planemo shed_update -t testtoolshed --check_diff tools/count_roi_variants/ |
0 | 100 ... |
101 | |
102 or:: | |
103 | |
8
7f6a56260be6
planemo upload for repository https://github.com/peterjc/pico_galaxy/tree/master/tools/count_roi_variants commit 7f8f223933c405b821dbfee3edcd4f111633636a-dirty
peterjc
parents:
4
diff
changeset
|
104 $ planemo shed_update -t toolshed --check_diff tools/count_roi_variants/ |
0 | 105 ... |
106 | |
107 To just build and check the tar ball, use:: | |
108 | |
8
7f6a56260be6
planemo upload for repository https://github.com/peterjc/pico_galaxy/tree/master/tools/count_roi_variants commit 7f8f223933c405b821dbfee3edcd4f111633636a-dirty
peterjc
parents:
4
diff
changeset
|
109 $ planemo shed_upload --tar_only tools/count_roi_variants/ |
0 | 110 ... |
111 $ tar -tzf shed_upload.tar.gz | |
112 tools/count_roi_variants/README.rst | |
113 tools/count_roi_variants/count_roi_variants.xml | |
114 tools/count_roi_variants/count_roi_variants.py | |
115 tools/count_roi_variants/tool_dependencies.xml | |
116 ... | |
117 | |
118 | |
119 Licence (MIT) | |
120 ============= | |
121 | |
122 Permission is hereby granted, free of charge, to any person obtaining a copy | |
123 of this software and associated documentation files (the "Software"), to deal | |
124 in the Software without restriction, including without limitation the rights | |
125 to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | |
126 copies of the Software, and to permit persons to whom the Software is | |
127 furnished to do so, subject to the following conditions: | |
128 | |
129 The above copyright notice and this permission notice shall be included in | |
130 all copies or substantial portions of the Software. | |
131 | |
132 THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | |
133 IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | |
134 FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | |
135 AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | |
136 LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | |
137 OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN | |
138 THE SOFTWARE. | |
139 | |
140 NOTE: This is the licence for the Galaxy Wrapper only. | |
141 samtools is available and licenced separately. |