PyamilySeq 0.8.1__tar.gz → 1.0.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- pyamilyseq-1.0.0/PKG-INFO +17 -0
- pyamilyseq-1.0.0/README.md +2 -0
- {pyamilyseq-0.8.1 → pyamilyseq-1.0.0}/setup.cfg +5 -7
- pyamilyseq-1.0.0/src/PyamilySeq.egg-info/PKG-INFO +17 -0
- pyamilyseq-1.0.0/src/PyamilySeq.egg-info/SOURCES.txt +9 -0
- pyamilyseq-1.0.0/src/PyamilySeq.egg-info/entry_points.txt +2 -0
- pyamilyseq-1.0.0/src/PyamilySeq.egg-info/top_level.txt +1 -0
- pyamilyseq-0.8.1/PKG-INFO +0 -287
- pyamilyseq-0.8.1/README.md +0 -272
- pyamilyseq-0.8.1/src/PyamilySeq/Constants.py +0 -2
- pyamilyseq-0.8.1/src/PyamilySeq/Group_Splitter.py +0 -350
- pyamilyseq-0.8.1/src/PyamilySeq/PyamilySeq.py +0 -295
- pyamilyseq-0.8.1/src/PyamilySeq/PyamilySeq_Genus.py +0 -242
- pyamilyseq-0.8.1/src/PyamilySeq/PyamilySeq_Species.py +0 -287
- pyamilyseq-0.8.1/src/PyamilySeq/Seq_Combiner.py +0 -63
- pyamilyseq-0.8.1/src/PyamilySeq/__init__.py +0 -0
- pyamilyseq-0.8.1/src/PyamilySeq/clusterings.py +0 -362
- pyamilyseq-0.8.1/src/PyamilySeq/utils.py +0 -432
- pyamilyseq-0.8.1/src/PyamilySeq.egg-info/PKG-INFO +0 -287
- pyamilyseq-0.8.1/src/PyamilySeq.egg-info/SOURCES.txt +0 -18
- pyamilyseq-0.8.1/src/PyamilySeq.egg-info/entry_points.txt +0 -4
- pyamilyseq-0.8.1/src/PyamilySeq.egg-info/top_level.txt +0 -1
- {pyamilyseq-0.8.1 → pyamilyseq-1.0.0}/LICENSE +0 -0
- {pyamilyseq-0.8.1 → pyamilyseq-1.0.0}/pyproject.toml +0 -0
- {pyamilyseq-0.8.1 → pyamilyseq-1.0.0}/src/PyamilySeq.egg-info/dependency_links.txt +0 -0
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
Metadata-Version: 2.1
|
|
2
|
+
Name: PyamilySeq
|
|
3
|
+
Version: 1.0.0
|
|
4
|
+
Summary: rORForise - A a tool to study read-level gene predictions.
|
|
5
|
+
Home-page: https://github.com/NickJD/rORForise
|
|
6
|
+
Author: Nicholas Dimonaco
|
|
7
|
+
Author-email: nicholas@dimonaco.co.uk
|
|
8
|
+
Project-URL: Bug Tracker, https://github.com/NickJD/rORForise/issues
|
|
9
|
+
Classifier: Programming Language :: Python :: 3
|
|
10
|
+
Classifier: License :: OSI Approved :: GNU General Public License v3 (GPLv3)
|
|
11
|
+
Classifier: Operating System :: OS Independent
|
|
12
|
+
Requires-Python: >=3.6
|
|
13
|
+
Description-Content-Type: text/markdown
|
|
14
|
+
License-File: LICENSE
|
|
15
|
+
|
|
16
|
+
# rORForise
|
|
17
|
+
Read-based gene coverage evaluation
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
[metadata]
|
|
2
2
|
name = PyamilySeq
|
|
3
|
-
version =
|
|
3
|
+
version = v1.0.0
|
|
4
4
|
author = Nicholas Dimonaco
|
|
5
5
|
author_email = nicholas@dimonaco.co.uk
|
|
6
|
-
description =
|
|
6
|
+
description = rORForise - A a tool to study read-level gene predictions.
|
|
7
7
|
long_description = file: README.md
|
|
8
8
|
long_description_content_type = text/markdown
|
|
9
|
-
url = https://github.com/NickJD/
|
|
9
|
+
url = https://github.com/NickJD/rORForise
|
|
10
10
|
project_urls =
|
|
11
|
-
Bug Tracker = https://github.com/NickJD/
|
|
11
|
+
Bug Tracker = https://github.com/NickJD/rORForise/issues
|
|
12
12
|
classifiers =
|
|
13
13
|
Programming Language :: Python :: 3
|
|
14
14
|
License :: OSI Approved :: GNU General Public License v3 (GPLv3)
|
|
@@ -27,9 +27,7 @@ include = *
|
|
|
27
27
|
|
|
28
28
|
[options.entry_points]
|
|
29
29
|
console_scripts =
|
|
30
|
-
|
|
31
|
-
Seq-Combiner = PyamilySeq.Seq_Combiner:main
|
|
32
|
-
Group-Splitter = PyamilySeq.Group_Splitter:main
|
|
30
|
+
eval = rORForise.evaluate:main
|
|
33
31
|
|
|
34
32
|
[egg_info]
|
|
35
33
|
tag_build =
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
Metadata-Version: 2.1
|
|
2
|
+
Name: PyamilySeq
|
|
3
|
+
Version: 1.0.0
|
|
4
|
+
Summary: rORForise - A a tool to study read-level gene predictions.
|
|
5
|
+
Home-page: https://github.com/NickJD/rORForise
|
|
6
|
+
Author: Nicholas Dimonaco
|
|
7
|
+
Author-email: nicholas@dimonaco.co.uk
|
|
8
|
+
Project-URL: Bug Tracker, https://github.com/NickJD/rORForise/issues
|
|
9
|
+
Classifier: Programming Language :: Python :: 3
|
|
10
|
+
Classifier: License :: OSI Approved :: GNU General Public License v3 (GPLv3)
|
|
11
|
+
Classifier: Operating System :: OS Independent
|
|
12
|
+
Requires-Python: >=3.6
|
|
13
|
+
Description-Content-Type: text/markdown
|
|
14
|
+
License-File: LICENSE
|
|
15
|
+
|
|
16
|
+
# rORForise
|
|
17
|
+
Read-based gene coverage evaluation
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
|
pyamilyseq-0.8.1/PKG-INFO
DELETED
|
@@ -1,287 +0,0 @@
|
|
|
1
|
-
Metadata-Version: 2.1
|
|
2
|
-
Name: PyamilySeq
|
|
3
|
-
Version: 0.8.1
|
|
4
|
-
Summary: PyamilySeq - A a tool to look for sequence-based gene groups identified by clustering methods such as CD-HIT, DIAMOND, BLAST or MMseqs2.
|
|
5
|
-
Home-page: https://github.com/NickJD/PyamilySeq
|
|
6
|
-
Author: Nicholas Dimonaco
|
|
7
|
-
Author-email: nicholas@dimonaco.co.uk
|
|
8
|
-
Project-URL: Bug Tracker, https://github.com/NickJD/PyamilySeq/issues
|
|
9
|
-
Classifier: Programming Language :: Python :: 3
|
|
10
|
-
Classifier: License :: OSI Approved :: GNU General Public License v3 (GPLv3)
|
|
11
|
-
Classifier: Operating System :: OS Independent
|
|
12
|
-
Requires-Python: >=3.6
|
|
13
|
-
Description-Content-Type: text/markdown
|
|
14
|
-
License-File: LICENSE
|
|
15
|
-
|
|
16
|
-
# PyamilySeq - !BETA!
|
|
17
|
-
**PyamilySeq** is a Python tool for clustering gene sequences into groups based on sequence similarity identified by tools such as CD-HIT, BLAST, DIAMOND or MMseqs2.
|
|
18
|
-
This work is an extension of the gene family / pangenome tool developed for the StORF-Reporter publication in NAR (https://doi.org/10.1093/nar/gkad814).
|
|
19
|
-
|
|
20
|
-
## Features
|
|
21
|
-
- **End-to-End**: PyamilySeq can take a directory of GFF+FASTA files, run CD-HIT for clustering and process the results.
|
|
22
|
-
- **Clustering input**: Supports input from CD-HIT formatted files as well as CSV and TSV edge lists (MMseqs2 and -outfmt 6 from BLAST/DIAMOND).
|
|
23
|
-
- **Reclustering**: Allows for the addition of new sequences post-initial clustering - Ensures continuity of contemporary clustering results and highlights impact of novel gene predictions.
|
|
24
|
-
- **'Genus Mode'**: Unlike other 'pangenome' tools, PyamilySeq can identify gene groups found across multiple genera as unique entities (see below).
|
|
25
|
-
- **Output**: Generates a 'Roary/Panaroo' formatted presence-absence CSV formatted file for downstream analysis.
|
|
26
|
-
- User-define species-/genus-wide gene groups - User has control over grouping parameters (core = 99/95% or min 6 genera etc).
|
|
27
|
-
- Aligns representative sequences using MAFFT.
|
|
28
|
-
- Output concatenated aligned sequences for tree building.
|
|
29
|
-
- Optionally output sequences of each separate identified gene group.
|
|
30
|
-
|
|
31
|
-
## Installation
|
|
32
|
-
PyamilySeq probably requires Python 3.6 or higher. Install using pip:
|
|
33
|
-
|
|
34
|
-
```bash
|
|
35
|
-
pip install PyamilySeq
|
|
36
|
-
```
|
|
37
|
-
|
|
38
|
-
## Example usage: Below are two examples of running PyamilySeq in its two main modes.
|
|
39
|
-
### 'Full Mode': Will conduct clustering of sequences with CD-HIT as part of PyamilySeq run
|
|
40
|
-
```
|
|
41
|
-
PyamilySeq -run_mode Full -group_mode Species -clustering_format CD-HIT -output_dir .../test_data/testing/Full
|
|
42
|
-
-input_type combined -input_dir .../test_data/genomes -name_split _combined.gff3 -pid 0.95 -len_diff 0.80
|
|
43
|
-
-gpa -a -w 99
|
|
44
|
-
```
|
|
45
|
-
### 'Partial Mode': Will take the output of a sequence clustering.
|
|
46
|
-
```
|
|
47
|
-
PyamilySeq -run_mode Partial -group_mode Species -clustering_format TSV -output_dir .../test_data/Species/testing/Partial
|
|
48
|
-
-cluster_file .../test_data/Species/MMseqs2/combined_Ensmbl_pep_cluster.tsv
|
|
49
|
-
-original_fasta .../test_data/species/combined_Ensmbl_cds.fasta -gpa -a -w 99 -verbose
|
|
50
|
-
|
|
51
|
-
```
|
|
52
|
-
#### Note: '-clustering_format TSV/CSV' requires input to be two in two columns as below (Same format as MMseqs2 tsv) - Genome name and sequence name are separated by '|'.
|
|
53
|
-
```
|
|
54
|
-
Escherichia_coli_110957|ENSB:lL-zIKt-gh0oSno Escherichia_coli_110957|ENSB:lL-zIKt-gh0oSno
|
|
55
|
-
Escherichia_coli_110957|ENSB:lL-zIKt-gh0oSno Escherichia_coli_113290|ENSB:2fj4rJ8e8Z9PNdX
|
|
56
|
-
Escherichia_coli_110957|ENSB:lL-zIKt-gh0oSno Escherichia_coli_b185|ENSB:G_PVe28-ej8q-3S
|
|
57
|
-
Escherichia_coli_110957|ENSB:TIZS9kbTvShDvyX Escherichia_coli_110957|ENSB:TIZS9kbTvShDvyX
|
|
58
|
-
```
|
|
59
|
-
### Example output:
|
|
60
|
-
```
|
|
61
|
-
Running PyamilySeq v0.8.1
|
|
62
|
-
Calculating Groups
|
|
63
|
-
Gene Groups:
|
|
64
|
-
First_core_99: 2682
|
|
65
|
-
First_core_95: 0
|
|
66
|
-
First_core_15: 3789
|
|
67
|
-
First_core_0: 6469
|
|
68
|
-
Total Number of First Gene Groups (Including Singletons): 12940
|
|
69
|
-
Outputting gene_presence_absence file
|
|
70
|
-
Outputting gene group FASTA files
|
|
71
|
-
Processing gene group alignment
|
|
72
|
-
Thank you for using PyamilySeq -- A detailed user manual can be found at https://github.com/NickJD/PyamilySeq
|
|
73
|
-
Please report any issues to: https://github.com/NickJD/PyamilySeq/issues
|
|
74
|
-
```
|
|
75
|
-
## Genus mode:
|
|
76
|
-
### In addition to "Species mode" (see above) which reports gene groups the same as pangenome tools such as Roary and Panaroo, Genus mode reports gene groups identified across multiple genera.
|
|
77
|
-
#### Example:
|
|
78
|
-
```
|
|
79
|
-
PyamilySeq -run_mode Partial -group_mode Genus -clustering_format CD-HIT -output_dir .../test_data/genus/testing/
|
|
80
|
-
-cluster_file .../test_data/genus/CD-HIT/combined_cds_cd-hit_80_60.clstr -gpa
|
|
81
|
-
```
|
|
82
|
-
```commandline
|
|
83
|
-
Running PyamilySeq v0.8.1
|
|
84
|
-
Calculating Groups
|
|
85
|
-
Genus Groups:
|
|
86
|
-
First_genera_1: 28549
|
|
87
|
-
First_genera_2: 12
|
|
88
|
-
First_genera_3: 0
|
|
89
|
-
First_genera_>: 0
|
|
90
|
-
Total Number of First Gene Groups (Including Singletons): 28561
|
|
91
|
-
Outputting gene_presence_absence file
|
|
92
|
-
Thank you for using PyamilySeq -- A detailed user manual can be found at https://github.com/NickJD/PyamilySeq
|
|
93
|
-
Please report any issues to: https://github.com/NickJD/PyamilySeq/issues
|
|
94
|
-
#####
|
|
95
|
-
```
|
|
96
|
-
|
|
97
|
-
## Reclustering:
|
|
98
|
-
### Reclustering can be used to see where additional sequences/genes lay in relation to a contemporary pangenome/gene grouping.
|
|
99
|
-
```
|
|
100
|
-
PyamilySeq -run_mode Partial -group_mode Species -clustering_format CD-HIT -output_dir .../test_data/species/CD-HIT/testing
|
|
101
|
-
-cluster_file .../test_data/species/CD-HIT/E-coli_extracted_cds_cd-hit_80_60.clstr -gpa
|
|
102
|
-
-reclustered .../test_data/species/CD-HIT/E-coli_extracted_cds_cd-hit_80_60_And_StORFs_cds_80_60.clstr
|
|
103
|
-
```
|
|
104
|
-
#### As can be seen below, the additional sequences recovered by the StORF-Reporter annotation tool have 'extended' contemporary or created entirely new gene groups. 'First' corresponds to the groups identified from the first clustering round and 'Second' for the second. In 'reclustering' mode, First_core_# groups are unaffected thus retaining the initial grouping information.
|
|
105
|
-
```commandline
|
|
106
|
-
Calculating Groups
|
|
107
|
-
Gene Groups:
|
|
108
|
-
First_core_99: 587
|
|
109
|
-
First_core_95: 1529
|
|
110
|
-
First_core_15: 3708
|
|
111
|
-
First_core_0: 29992
|
|
112
|
-
extended_core_99: 29
|
|
113
|
-
extended_core_95: 67
|
|
114
|
-
extended_core_15: 431
|
|
115
|
-
extended_core_0: 1331
|
|
116
|
-
combined_core_99: 2
|
|
117
|
-
combined_core_95: 4
|
|
118
|
-
combined_core_15: 5
|
|
119
|
-
combined_core_0: 4
|
|
120
|
-
Second_core_99: 0
|
|
121
|
-
Second_core_95: 6
|
|
122
|
-
Second_core_15: 172
|
|
123
|
-
Second_core_0: 1825
|
|
124
|
-
only_Second_core_99: 53
|
|
125
|
-
only_Second_core_95: 493
|
|
126
|
-
only_Second_core_15: 3806
|
|
127
|
-
only_Second_core_0: 27569
|
|
128
|
-
Total Number of First Gene Groups (Including Singletons): 35816
|
|
129
|
-
Total Number of Second Gene Groups (Including Singletons): 67728
|
|
130
|
-
Total Number of First Gene Groups That Had Additional Second Sequences But Not New Genomes: 136
|
|
131
|
-
Outputting gene_presence_absence file
|
|
132
|
-
Thank you for using PyamilySeq -- A detailed user manual can be found at https://github.com/NickJD/PyamilySeq
|
|
133
|
-
Please report any issues to: https://github.com/NickJD/PyamilySeq/issues
|
|
134
|
-
#####
|
|
135
|
-
```
|
|
136
|
-
|
|
137
|
-
## PyamilySeq - Menu:
|
|
138
|
-
### PyamilySeq is separated into two main 'run modes', Full and Partial. They each have their own set of required and optional arguments.
|
|
139
|
-
```
|
|
140
|
-
Running PyamilySeq v0.8.1
|
|
141
|
-
usage: PyamilySeq.py [-h] -run_mode {Full,Partial} -group_mode {Species,Genus} -clustering_format {CD-HIT,TSV,CSV} -output_dir OUTPUT_DIR
|
|
142
|
-
[-input_type {separate,combined}] [-input_dir INPUT_DIR] [-name_split NAME_SPLIT] [-sequence_type {AA,DNA}] [-gene_ident GENE_IDENT]
|
|
143
|
-
[-pid PIDENT] [-len_diff LEN_DIFF] [-mem CLUSTERING_MEMORY] [-t CLUSTERING_THREADS] [-cluster_file CLUSTER_FILE]
|
|
144
|
-
[-reclustered RECLUSTERED] [-seq_tag SEQUENCE_TAG] [-core_groups CORE_GROUPS] [-genus_groups GENUS_GROUPS] [-w WRITE_GROUPS] [-a]
|
|
145
|
-
[-original_fasta ORIGINAL_FASTA] [-gpa] [-verbose] [-v]
|
|
146
|
-
|
|
147
|
-
PyamilySeq v0.8.1: A tool that groups genes into unique clusters.
|
|
148
|
-
|
|
149
|
-
options:
|
|
150
|
-
-h, --help show this help message and exit
|
|
151
|
-
|
|
152
|
-
Required Arguments:
|
|
153
|
-
-run_mode {Full,Partial}
|
|
154
|
-
Run Mode: Should PyamilySeq be run in "Full" or "Partial" mode?
|
|
155
|
-
-group_mode {Species,Genus}
|
|
156
|
-
Group Mode: Should PyamilySeq be run in "Species" or "Genus" mode?
|
|
157
|
-
-clustering_format {CD-HIT,TSV,CSV}
|
|
158
|
-
Clustering format to use: CD-HIT or TSV (MMseqs2, BLAST, DIAMOND) / CSV edge-list file (Node1 Node2).
|
|
159
|
-
-output_dir OUTPUT_DIR
|
|
160
|
-
Directory for all output files.
|
|
161
|
-
|
|
162
|
-
Full-Mode Arguments - Required when "-run_mode Full" is used:
|
|
163
|
-
-input_type {separate,combined}
|
|
164
|
-
Type of input files: 'separate' for separate FASTA and GFF files, 'combined' for GFF files with embedded FASTA sequences.
|
|
165
|
-
-input_dir INPUT_DIR Directory containing GFF/FASTA files.
|
|
166
|
-
-name_split NAME_SPLIT
|
|
167
|
-
substring used to split the filename and extract the genome name ('_combined.gff3' or '.gff').
|
|
168
|
-
-sequence_type {AA,DNA}
|
|
169
|
-
Default - DNA: Should clustering be performed in "DNA" or "AA" mode?
|
|
170
|
-
-gene_ident GENE_IDENT
|
|
171
|
-
Identifier used for extraction of sequences such as
|
|
172
|
-
"misc_RNA,gene,mRNA,CDS,rRNA,tRNA,tmRNA,CRISPR,ncRNA,regulatory_region,oriC,pseudo"
|
|
173
|
-
-pid PIDENT Default 0.95: Pident threshold for clustering.
|
|
174
|
-
-len_diff LEN_DIFF Default 0.80: Minimum length difference between clustered sequences - (-s) threshold for CD-HIT clustering.
|
|
175
|
-
|
|
176
|
-
Clustering Runtime Arguments - Optional when "-run_mode Full" is used:
|
|
177
|
-
-mem CLUSTERING_MEMORY
|
|
178
|
-
Default 4000: Memory to be allocated for clustering (in MBs).
|
|
179
|
-
-t THREADS Default 8: Threads to be allocated for clustering
|
|
180
|
-
and/or alignment.
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
Partial-Mode Arguments - Required when "-run_mode Partial" is used:
|
|
184
|
-
-cluster_file CLUSTER_FILE
|
|
185
|
-
Clustering output file containing CD-HIT, TSV or CSV Edge List
|
|
186
|
-
|
|
187
|
-
Grouping Arguments - Use to fine-tune grouping of genes after clustering:
|
|
188
|
-
-reclustered RECLUSTERED
|
|
189
|
-
Currently only works on Partial Mode: Clustering output file from secondary round of clustering.
|
|
190
|
-
-seq_tag SEQUENCE_TAG
|
|
191
|
-
Default - "StORF": Unique identifier to be used to distinguish the second of two rounds of clustered sequences
|
|
192
|
-
-core_groups CORE_GROUPS
|
|
193
|
-
Default - ('99,95,15'): Gene family groups to use for "Species" mode
|
|
194
|
-
-genus_groups GENUS_GROUPS
|
|
195
|
-
Default - ('1,2,3,4,5,6'): Gene family groups to use for "Genus" mode
|
|
196
|
-
|
|
197
|
-
Output Parameters:
|
|
198
|
-
-w WRITE_GROUPS Default - No output: Output sequences of identified groups (provide levels at which to output - Species "-w 99,95" Genus "-w 2,3" -
|
|
199
|
-
Must provide FASTA file with -original_fasta if in Partial run mode.
|
|
200
|
-
-a Default - No output: SLOW! (Only works for Species mode) Output aligned and concatinated sequences of identified groups -provide
|
|
201
|
-
group levels at which to output "-w 99,95" - Must provide FASTA file with -original_fasta in Partial run mode.
|
|
202
|
-
-original_fasta ORIGINAL_FASTA
|
|
203
|
-
FASTA file to use in conjunction with "-w" or "-a" when running in Partial Mode.
|
|
204
|
-
-gpa Default - False: If selected, a Roary/Panaroo formatted gene_presence_absence.csv will be created - Required for Coinfinder and
|
|
205
|
-
other downstream tools
|
|
206
|
-
|
|
207
|
-
Misc:
|
|
208
|
-
-verbose Default - False: Print out runtime messages
|
|
209
|
-
-v Default - False: Print out version number and exit
|
|
210
|
-
```
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
## Seq-Combiner: This tool is provided to enable the pre-processing of multiple GFF/FASTA files together ready to be clustered by the user.
|
|
217
|
-
### Example:
|
|
218
|
-
```bash
|
|
219
|
-
Seq-Combiner -input_dir .../test_data/genomes -name_split _combined.gff3 -output_dir.../test_data -output_name combine_fasta_seqs.fa -input_type combined
|
|
220
|
-
```
|
|
221
|
-
### Seq-Combiner Menu:
|
|
222
|
-
```
|
|
223
|
-
usage: Seq_Combiner.py [-h] -input_dir INPUT_DIR -input_type {separate,combined,fasta} -name_split NAME_SPLIT -output_dir OUTPUT_DIR -output_name OUTPUT_FILE [-gene_ident GENE_IDENT] [-translate] [-v]
|
|
224
|
-
|
|
225
|
-
Seq-Combiner v0.8.1: A tool to extract sequences from GFF/FASTA files.
|
|
226
|
-
|
|
227
|
-
options:
|
|
228
|
-
-h, --help show this help message and exit
|
|
229
|
-
|
|
230
|
-
Required Arguments:
|
|
231
|
-
-input_dir INPUT_DIR Directory location where the files are located.
|
|
232
|
-
-input_type {separate,combined,fasta}
|
|
233
|
-
Type of input files: "separate" for separate FASTA and GFF files, "combined" for GFF files with embedded FASTA sequences and "fasta" for combining multiple FASTA files together.
|
|
234
|
-
-name_split NAME_SPLIT
|
|
235
|
-
substring used to split the filename and extract the genome name ('_combined.gff3' or '.gff').
|
|
236
|
-
-output_dir OUTPUT_DIR
|
|
237
|
-
Directory for all output files.
|
|
238
|
-
-output_name OUTPUT_FILE
|
|
239
|
-
Output file name.
|
|
240
|
-
|
|
241
|
-
Optional Arguments:
|
|
242
|
-
-gene_ident GENE_IDENT
|
|
243
|
-
Default - "CDS": Identifier used for extraction of sequences such as "misc_RNA,gene,mRNA,CDS,rRNA,tRNA,tmRNA,CRISPR,ncRNA,regulatory_region,oriC,pseudo" - Not compatible with "fasta" input mode.
|
|
244
|
-
-translate Default - False: Translate extracted sequences to their AA counterpart?
|
|
245
|
-
|
|
246
|
-
Misc Arguments:
|
|
247
|
-
-v Print out version number and exit
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
```
|
|
251
|
-
|
|
252
|
-
### Group-Splitter menu:
|
|
253
|
-
|
|
254
|
-
```
|
|
255
|
-
usage: Group_Splitter.py [-h] -input_fasta INPUT_FASTA -output_dir OUTPUT_DIR [-pident PIDENT] [-len_diff LEN_DIFF] [-clustering_threads CLUSTERING_THREADS]
|
|
256
|
-
[-clustering_memory CLUSTERING_MEMORY] [-percent_threshold PERCENT_THRESHOLD] [-verbose] [-delete_temp_files] [-v]
|
|
257
|
-
|
|
258
|
-
Group-Splitter: v0.8.1: A tool to split "paralogous" groups identified by PyamilySeq.
|
|
259
|
-
|
|
260
|
-
options:
|
|
261
|
-
-h, --help show this help message and exit
|
|
262
|
-
|
|
263
|
-
Required Arguments:
|
|
264
|
-
-input_fasta INPUT_FASTA
|
|
265
|
-
Input FASTA file containing gene groups.
|
|
266
|
-
-sequence_type {AA,DNA}
|
|
267
|
-
Default - DNA: Are groups "DNA" or "AA" sequences?
|
|
268
|
-
-output_dir OUTPUT_DIR
|
|
269
|
-
Output directory.
|
|
270
|
-
|
|
271
|
-
Optional Arguments:
|
|
272
|
-
-pident PIDENT Sequence identity threshold (default: 0.9)
|
|
273
|
-
-len_diff LEN_DIFF Length difference threshold (default: 0.05)
|
|
274
|
-
-clustering_threads CLUSTERING_THREADS
|
|
275
|
-
Number of threads for clustering (default: 4)
|
|
276
|
-
-clustering_memory CLUSTERING_MEMORY
|
|
277
|
-
Memory limit in MB for clustering (default: 2000)
|
|
278
|
-
-percent_threshold PERCENT_THRESHOLD
|
|
279
|
-
Minimum percentage of genomes with paralogs (default: 80.0)
|
|
280
|
-
-verbose Print verbose output.
|
|
281
|
-
-delete_temp_files Delete all temporary files after processing.
|
|
282
|
-
|
|
283
|
-
Misc Arguments:
|
|
284
|
-
-v Print out version number and exit
|
|
285
|
-
```
|
|
286
|
-
|
|
287
|
-
### All example input and output data can be found in the 'test_data' directory.
|
pyamilyseq-0.8.1/README.md
DELETED
|
@@ -1,272 +0,0 @@
|
|
|
1
|
-
# PyamilySeq - !BETA!
|
|
2
|
-
**PyamilySeq** is a Python tool for clustering gene sequences into groups based on sequence similarity identified by tools such as CD-HIT, BLAST, DIAMOND or MMseqs2.
|
|
3
|
-
This work is an extension of the gene family / pangenome tool developed for the StORF-Reporter publication in NAR (https://doi.org/10.1093/nar/gkad814).
|
|
4
|
-
|
|
5
|
-
## Features
|
|
6
|
-
- **End-to-End**: PyamilySeq can take a directory of GFF+FASTA files, run CD-HIT for clustering and process the results.
|
|
7
|
-
- **Clustering input**: Supports input from CD-HIT formatted files as well as CSV and TSV edge lists (MMseqs2 and -outfmt 6 from BLAST/DIAMOND).
|
|
8
|
-
- **Reclustering**: Allows for the addition of new sequences post-initial clustering - Ensures continuity of contemporary clustering results and highlights impact of novel gene predictions.
|
|
9
|
-
- **'Genus Mode'**: Unlike other 'pangenome' tools, PyamilySeq can identify gene groups found across multiple genera as unique entities (see below).
|
|
10
|
-
- **Output**: Generates a 'Roary/Panaroo' formatted presence-absence CSV formatted file for downstream analysis.
|
|
11
|
-
- User-define species-/genus-wide gene groups - User has control over grouping parameters (core = 99/95% or min 6 genera etc).
|
|
12
|
-
- Aligns representative sequences using MAFFT.
|
|
13
|
-
- Output concatenated aligned sequences for tree building.
|
|
14
|
-
- Optionally output sequences of each separate identified gene group.
|
|
15
|
-
|
|
16
|
-
## Installation
|
|
17
|
-
PyamilySeq probably requires Python 3.6 or higher. Install using pip:
|
|
18
|
-
|
|
19
|
-
```bash
|
|
20
|
-
pip install PyamilySeq
|
|
21
|
-
```
|
|
22
|
-
|
|
23
|
-
## Example usage: Below are two examples of running PyamilySeq in its two main modes.
|
|
24
|
-
### 'Full Mode': Will conduct clustering of sequences with CD-HIT as part of PyamilySeq run
|
|
25
|
-
```
|
|
26
|
-
PyamilySeq -run_mode Full -group_mode Species -clustering_format CD-HIT -output_dir .../test_data/testing/Full
|
|
27
|
-
-input_type combined -input_dir .../test_data/genomes -name_split _combined.gff3 -pid 0.95 -len_diff 0.80
|
|
28
|
-
-gpa -a -w 99
|
|
29
|
-
```
|
|
30
|
-
### 'Partial Mode': Will take the output of a sequence clustering.
|
|
31
|
-
```
|
|
32
|
-
PyamilySeq -run_mode Partial -group_mode Species -clustering_format TSV -output_dir .../test_data/Species/testing/Partial
|
|
33
|
-
-cluster_file .../test_data/Species/MMseqs2/combined_Ensmbl_pep_cluster.tsv
|
|
34
|
-
-original_fasta .../test_data/species/combined_Ensmbl_cds.fasta -gpa -a -w 99 -verbose
|
|
35
|
-
|
|
36
|
-
```
|
|
37
|
-
#### Note: '-clustering_format TSV/CSV' requires input to be two in two columns as below (Same format as MMseqs2 tsv) - Genome name and sequence name are separated by '|'.
|
|
38
|
-
```
|
|
39
|
-
Escherichia_coli_110957|ENSB:lL-zIKt-gh0oSno Escherichia_coli_110957|ENSB:lL-zIKt-gh0oSno
|
|
40
|
-
Escherichia_coli_110957|ENSB:lL-zIKt-gh0oSno Escherichia_coli_113290|ENSB:2fj4rJ8e8Z9PNdX
|
|
41
|
-
Escherichia_coli_110957|ENSB:lL-zIKt-gh0oSno Escherichia_coli_b185|ENSB:G_PVe28-ej8q-3S
|
|
42
|
-
Escherichia_coli_110957|ENSB:TIZS9kbTvShDvyX Escherichia_coli_110957|ENSB:TIZS9kbTvShDvyX
|
|
43
|
-
```
|
|
44
|
-
### Example output:
|
|
45
|
-
```
|
|
46
|
-
Running PyamilySeq v0.8.1
|
|
47
|
-
Calculating Groups
|
|
48
|
-
Gene Groups:
|
|
49
|
-
First_core_99: 2682
|
|
50
|
-
First_core_95: 0
|
|
51
|
-
First_core_15: 3789
|
|
52
|
-
First_core_0: 6469
|
|
53
|
-
Total Number of First Gene Groups (Including Singletons): 12940
|
|
54
|
-
Outputting gene_presence_absence file
|
|
55
|
-
Outputting gene group FASTA files
|
|
56
|
-
Processing gene group alignment
|
|
57
|
-
Thank you for using PyamilySeq -- A detailed user manual can be found at https://github.com/NickJD/PyamilySeq
|
|
58
|
-
Please report any issues to: https://github.com/NickJD/PyamilySeq/issues
|
|
59
|
-
```
|
|
60
|
-
## Genus mode:
|
|
61
|
-
### In addition to "Species mode" (see above) which reports gene groups the same as pangenome tools such as Roary and Panaroo, Genus mode reports gene groups identified across multiple genera.
|
|
62
|
-
#### Example:
|
|
63
|
-
```
|
|
64
|
-
PyamilySeq -run_mode Partial -group_mode Genus -clustering_format CD-HIT -output_dir .../test_data/genus/testing/
|
|
65
|
-
-cluster_file .../test_data/genus/CD-HIT/combined_cds_cd-hit_80_60.clstr -gpa
|
|
66
|
-
```
|
|
67
|
-
```commandline
|
|
68
|
-
Running PyamilySeq v0.8.1
|
|
69
|
-
Calculating Groups
|
|
70
|
-
Genus Groups:
|
|
71
|
-
First_genera_1: 28549
|
|
72
|
-
First_genera_2: 12
|
|
73
|
-
First_genera_3: 0
|
|
74
|
-
First_genera_>: 0
|
|
75
|
-
Total Number of First Gene Groups (Including Singletons): 28561
|
|
76
|
-
Outputting gene_presence_absence file
|
|
77
|
-
Thank you for using PyamilySeq -- A detailed user manual can be found at https://github.com/NickJD/PyamilySeq
|
|
78
|
-
Please report any issues to: https://github.com/NickJD/PyamilySeq/issues
|
|
79
|
-
#####
|
|
80
|
-
```
|
|
81
|
-
|
|
82
|
-
## Reclustering:
|
|
83
|
-
### Reclustering can be used to see where additional sequences/genes lay in relation to a contemporary pangenome/gene grouping.
|
|
84
|
-
```
|
|
85
|
-
PyamilySeq -run_mode Partial -group_mode Species -clustering_format CD-HIT -output_dir .../test_data/species/CD-HIT/testing
|
|
86
|
-
-cluster_file .../test_data/species/CD-HIT/E-coli_extracted_cds_cd-hit_80_60.clstr -gpa
|
|
87
|
-
-reclustered .../test_data/species/CD-HIT/E-coli_extracted_cds_cd-hit_80_60_And_StORFs_cds_80_60.clstr
|
|
88
|
-
```
|
|
89
|
-
#### As can be seen below, the additional sequences recovered by the StORF-Reporter annotation tool have 'extended' contemporary or created entirely new gene groups. 'First' corresponds to the groups identified from the first clustering round and 'Second' for the second. In 'reclustering' mode, First_core_# groups are unaffected thus retaining the initial grouping information.
|
|
90
|
-
```commandline
|
|
91
|
-
Calculating Groups
|
|
92
|
-
Gene Groups:
|
|
93
|
-
First_core_99: 587
|
|
94
|
-
First_core_95: 1529
|
|
95
|
-
First_core_15: 3708
|
|
96
|
-
First_core_0: 29992
|
|
97
|
-
extended_core_99: 29
|
|
98
|
-
extended_core_95: 67
|
|
99
|
-
extended_core_15: 431
|
|
100
|
-
extended_core_0: 1331
|
|
101
|
-
combined_core_99: 2
|
|
102
|
-
combined_core_95: 4
|
|
103
|
-
combined_core_15: 5
|
|
104
|
-
combined_core_0: 4
|
|
105
|
-
Second_core_99: 0
|
|
106
|
-
Second_core_95: 6
|
|
107
|
-
Second_core_15: 172
|
|
108
|
-
Second_core_0: 1825
|
|
109
|
-
only_Second_core_99: 53
|
|
110
|
-
only_Second_core_95: 493
|
|
111
|
-
only_Second_core_15: 3806
|
|
112
|
-
only_Second_core_0: 27569
|
|
113
|
-
Total Number of First Gene Groups (Including Singletons): 35816
|
|
114
|
-
Total Number of Second Gene Groups (Including Singletons): 67728
|
|
115
|
-
Total Number of First Gene Groups That Had Additional Second Sequences But Not New Genomes: 136
|
|
116
|
-
Outputting gene_presence_absence file
|
|
117
|
-
Thank you for using PyamilySeq -- A detailed user manual can be found at https://github.com/NickJD/PyamilySeq
|
|
118
|
-
Please report any issues to: https://github.com/NickJD/PyamilySeq/issues
|
|
119
|
-
#####
|
|
120
|
-
```
|
|
121
|
-
|
|
122
|
-
## PyamilySeq - Menu:
|
|
123
|
-
### PyamilySeq is separated into two main 'run modes', Full and Partial. They each have their own set of required and optional arguments.
|
|
124
|
-
```
|
|
125
|
-
Running PyamilySeq v0.8.1
|
|
126
|
-
usage: PyamilySeq.py [-h] -run_mode {Full,Partial} -group_mode {Species,Genus} -clustering_format {CD-HIT,TSV,CSV} -output_dir OUTPUT_DIR
|
|
127
|
-
[-input_type {separate,combined}] [-input_dir INPUT_DIR] [-name_split NAME_SPLIT] [-sequence_type {AA,DNA}] [-gene_ident GENE_IDENT]
|
|
128
|
-
[-pid PIDENT] [-len_diff LEN_DIFF] [-mem CLUSTERING_MEMORY] [-t CLUSTERING_THREADS] [-cluster_file CLUSTER_FILE]
|
|
129
|
-
[-reclustered RECLUSTERED] [-seq_tag SEQUENCE_TAG] [-core_groups CORE_GROUPS] [-genus_groups GENUS_GROUPS] [-w WRITE_GROUPS] [-a]
|
|
130
|
-
[-original_fasta ORIGINAL_FASTA] [-gpa] [-verbose] [-v]
|
|
131
|
-
|
|
132
|
-
PyamilySeq v0.8.1: A tool that groups genes into unique clusters.
|
|
133
|
-
|
|
134
|
-
options:
|
|
135
|
-
-h, --help show this help message and exit
|
|
136
|
-
|
|
137
|
-
Required Arguments:
|
|
138
|
-
-run_mode {Full,Partial}
|
|
139
|
-
Run Mode: Should PyamilySeq be run in "Full" or "Partial" mode?
|
|
140
|
-
-group_mode {Species,Genus}
|
|
141
|
-
Group Mode: Should PyamilySeq be run in "Species" or "Genus" mode?
|
|
142
|
-
-clustering_format {CD-HIT,TSV,CSV}
|
|
143
|
-
Clustering format to use: CD-HIT or TSV (MMseqs2, BLAST, DIAMOND) / CSV edge-list file (Node1 Node2).
|
|
144
|
-
-output_dir OUTPUT_DIR
|
|
145
|
-
Directory for all output files.
|
|
146
|
-
|
|
147
|
-
Full-Mode Arguments - Required when "-run_mode Full" is used:
|
|
148
|
-
-input_type {separate,combined}
|
|
149
|
-
Type of input files: 'separate' for separate FASTA and GFF files, 'combined' for GFF files with embedded FASTA sequences.
|
|
150
|
-
-input_dir INPUT_DIR Directory containing GFF/FASTA files.
|
|
151
|
-
-name_split NAME_SPLIT
|
|
152
|
-
substring used to split the filename and extract the genome name ('_combined.gff3' or '.gff').
|
|
153
|
-
-sequence_type {AA,DNA}
|
|
154
|
-
Default - DNA: Should clustering be performed in "DNA" or "AA" mode?
|
|
155
|
-
-gene_ident GENE_IDENT
|
|
156
|
-
Identifier used for extraction of sequences such as
|
|
157
|
-
"misc_RNA,gene,mRNA,CDS,rRNA,tRNA,tmRNA,CRISPR,ncRNA,regulatory_region,oriC,pseudo"
|
|
158
|
-
-pid PIDENT Default 0.95: Pident threshold for clustering.
|
|
159
|
-
-len_diff LEN_DIFF Default 0.80: Minimum length difference between clustered sequences - (-s) threshold for CD-HIT clustering.
|
|
160
|
-
|
|
161
|
-
Clustering Runtime Arguments - Optional when "-run_mode Full" is used:
|
|
162
|
-
-mem CLUSTERING_MEMORY
|
|
163
|
-
Default 4000: Memory to be allocated for clustering (in MBs).
|
|
164
|
-
-t THREADS Default 8: Threads to be allocated for clustering
|
|
165
|
-
and/or alignment.
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
Partial-Mode Arguments - Required when "-run_mode Partial" is used:
|
|
169
|
-
-cluster_file CLUSTER_FILE
|
|
170
|
-
Clustering output file containing CD-HIT, TSV or CSV Edge List
|
|
171
|
-
|
|
172
|
-
Grouping Arguments - Use to fine-tune grouping of genes after clustering:
|
|
173
|
-
-reclustered RECLUSTERED
|
|
174
|
-
Currently only works on Partial Mode: Clustering output file from secondary round of clustering.
|
|
175
|
-
-seq_tag SEQUENCE_TAG
|
|
176
|
-
Default - "StORF": Unique identifier to be used to distinguish the second of two rounds of clustered sequences
|
|
177
|
-
-core_groups CORE_GROUPS
|
|
178
|
-
Default - ('99,95,15'): Gene family groups to use for "Species" mode
|
|
179
|
-
-genus_groups GENUS_GROUPS
|
|
180
|
-
Default - ('1,2,3,4,5,6'): Gene family groups to use for "Genus" mode
|
|
181
|
-
|
|
182
|
-
Output Parameters:
|
|
183
|
-
-w WRITE_GROUPS Default - No output: Output sequences of identified groups (provide levels at which to output - Species "-w 99,95" Genus "-w 2,3" -
|
|
184
|
-
Must provide FASTA file with -original_fasta if in Partial run mode.
|
|
185
|
-
-a Default - No output: SLOW! (Only works for Species mode) Output aligned and concatinated sequences of identified groups -provide
|
|
186
|
-
group levels at which to output "-w 99,95" - Must provide FASTA file with -original_fasta in Partial run mode.
|
|
187
|
-
-original_fasta ORIGINAL_FASTA
|
|
188
|
-
FASTA file to use in conjunction with "-w" or "-a" when running in Partial Mode.
|
|
189
|
-
-gpa Default - False: If selected, a Roary/Panaroo formatted gene_presence_absence.csv will be created - Required for Coinfinder and
|
|
190
|
-
other downstream tools
|
|
191
|
-
|
|
192
|
-
Misc:
|
|
193
|
-
-verbose Default - False: Print out runtime messages
|
|
194
|
-
-v Default - False: Print out version number and exit
|
|
195
|
-
```
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
## Seq-Combiner: This tool is provided to enable the pre-processing of multiple GFF/FASTA files together ready to be clustered by the user.
|
|
202
|
-
### Example:
|
|
203
|
-
```bash
|
|
204
|
-
Seq-Combiner -input_dir .../test_data/genomes -name_split _combined.gff3 -output_dir.../test_data -output_name combine_fasta_seqs.fa -input_type combined
|
|
205
|
-
```
|
|
206
|
-
### Seq-Combiner Menu:
|
|
207
|
-
```
|
|
208
|
-
usage: Seq_Combiner.py [-h] -input_dir INPUT_DIR -input_type {separate,combined,fasta} -name_split NAME_SPLIT -output_dir OUTPUT_DIR -output_name OUTPUT_FILE [-gene_ident GENE_IDENT] [-translate] [-v]
|
|
209
|
-
|
|
210
|
-
Seq-Combiner v0.8.1: A tool to extract sequences from GFF/FASTA files.
|
|
211
|
-
|
|
212
|
-
options:
|
|
213
|
-
-h, --help show this help message and exit
|
|
214
|
-
|
|
215
|
-
Required Arguments:
|
|
216
|
-
-input_dir INPUT_DIR Directory location where the files are located.
|
|
217
|
-
-input_type {separate,combined,fasta}
|
|
218
|
-
Type of input files: "separate" for separate FASTA and GFF files, "combined" for GFF files with embedded FASTA sequences and "fasta" for combining multiple FASTA files together.
|
|
219
|
-
-name_split NAME_SPLIT
|
|
220
|
-
substring used to split the filename and extract the genome name ('_combined.gff3' or '.gff').
|
|
221
|
-
-output_dir OUTPUT_DIR
|
|
222
|
-
Directory for all output files.
|
|
223
|
-
-output_name OUTPUT_FILE
|
|
224
|
-
Output file name.
|
|
225
|
-
|
|
226
|
-
Optional Arguments:
|
|
227
|
-
-gene_ident GENE_IDENT
|
|
228
|
-
Default - "CDS": Identifier used for extraction of sequences such as "misc_RNA,gene,mRNA,CDS,rRNA,tRNA,tmRNA,CRISPR,ncRNA,regulatory_region,oriC,pseudo" - Not compatible with "fasta" input mode.
|
|
229
|
-
-translate Default - False: Translate extracted sequences to their AA counterpart?
|
|
230
|
-
|
|
231
|
-
Misc Arguments:
|
|
232
|
-
-v Print out version number and exit
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
```
|
|
236
|
-
|
|
237
|
-
### Group-Splitter menu:
|
|
238
|
-
|
|
239
|
-
```
|
|
240
|
-
usage: Group_Splitter.py [-h] -input_fasta INPUT_FASTA -output_dir OUTPUT_DIR [-pident PIDENT] [-len_diff LEN_DIFF] [-clustering_threads CLUSTERING_THREADS]
|
|
241
|
-
[-clustering_memory CLUSTERING_MEMORY] [-percent_threshold PERCENT_THRESHOLD] [-verbose] [-delete_temp_files] [-v]
|
|
242
|
-
|
|
243
|
-
Group-Splitter: v0.8.1: A tool to split "paralogous" groups identified by PyamilySeq.
|
|
244
|
-
|
|
245
|
-
options:
|
|
246
|
-
-h, --help show this help message and exit
|
|
247
|
-
|
|
248
|
-
Required Arguments:
|
|
249
|
-
-input_fasta INPUT_FASTA
|
|
250
|
-
Input FASTA file containing gene groups.
|
|
251
|
-
-sequence_type {AA,DNA}
|
|
252
|
-
Default - DNA: Are groups "DNA" or "AA" sequences?
|
|
253
|
-
-output_dir OUTPUT_DIR
|
|
254
|
-
Output directory.
|
|
255
|
-
|
|
256
|
-
Optional Arguments:
|
|
257
|
-
-pident PIDENT Sequence identity threshold (default: 0.9)
|
|
258
|
-
-len_diff LEN_DIFF Length difference threshold (default: 0.05)
|
|
259
|
-
-clustering_threads CLUSTERING_THREADS
|
|
260
|
-
Number of threads for clustering (default: 4)
|
|
261
|
-
-clustering_memory CLUSTERING_MEMORY
|
|
262
|
-
Memory limit in MB for clustering (default: 2000)
|
|
263
|
-
-percent_threshold PERCENT_THRESHOLD
|
|
264
|
-
Minimum percentage of genomes with paralogs (default: 80.0)
|
|
265
|
-
-verbose Print verbose output.
|
|
266
|
-
-delete_temp_files Delete all temporary files after processing.
|
|
267
|
-
|
|
268
|
-
Misc Arguments:
|
|
269
|
-
-v Print out version number and exit
|
|
270
|
-
```
|
|
271
|
-
|
|
272
|
-
### All example input and output data can be found in the 'test_data' directory.
|