Skip to content

Commit

Permalink
Bug fixes and improvements (#4)
Browse files Browse the repository at this point in the history
* Change from minimap2 to winnowmap

- winnowmap performs better in repeat regions as shown in the paper https://doi.org/10.1093/bioinformatics/btaa435

* Add new error catch

* Add script to check if magnipore positions are within annotated regions

* add (0-based) information to readmes

* - changed default parameters for winnowmap
- fixed bug that doubled the read counts
- minor bug fixes
  • Loading branch information
JannesSP authored Nov 15, 2023
1 parent 81548a7 commit 95b4a82
Show file tree
Hide file tree
Showing 8 changed files with 186 additions and 405 deletions.
21 changes: 8 additions & 13 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,14 +31,6 @@ mamba create -n magnipore -c jannessp magnipore
conda activate magnipore
```

*Alternatively you can create a conda environment using the [conda_env.yml](conda.recipe/conda_env.yml) and mamba.*
```bash
conda install mamba
mamba env create -f conda/conda_env.yml
conda activate magnipore
git clone https://github.com/JannesSP/magnipore.git
```

If you want to basecall your ONT data you also need a Guppy version from [Oxford Nanopore Technologies](https://community.nanoporetech.com).

---
Expand Down Expand Up @@ -67,7 +59,7 @@ Conda Dependencies
- matplotlib>=3.6.2
- numpy>=1.23
- scipy>=1.9
- minimap2>=2.24
- winnowmap>=2.0
- pandas>=1.5
- seaborn>=0.12
- psutil>=5.9
Expand Down Expand Up @@ -173,7 +165,7 @@ The .magnipore file is a TSV containing the following columns.
- bayesian_p : p-value for the signal comparison
- signal_type : classification into "mod" for modification and "mut" for mutation
- ref_1 : contig name of sample 1
- pos_1 : position in contig of sample 1
- pos_1 : position in contig of sample 1 (0-based)
- base_1 : base at the position of sample 1
- motif_1 : motif around the base at the position of sample 1
- signal_mean_1 : mean of the signal distribution at the position of sample 1
Expand Down Expand Up @@ -205,31 +197,34 @@ Errors of first sample:
- 119: Cannot basecall .slow5/.blow5 with guppy
- 120: Could not find raw data or unknown file format
- 121: Guppy basecalling failed
- 122: minimap2 mapping failed
- 122: mapping failed
- 123: Samtools indexing failed
- 124: f5c index failed
- 125: f5c eventalign failed
- 126: Could not find provided fastq files
- 127: f5c eventalign file is empty
---
Errors of second sample
- 219: Cannot basecall .slow5/.blow5 with guppy
- 220: Could not find raw data or unknown file format
- 221: Guppy basecalling failed
- 222: minimap2 mapping failed
- 222: mapping failed
- 223: Samtools indexing failed
- 224: f5c index failed
- 225: f5c eventalign failed
- 226: Could not find provided fastq files
- 227: f5c eventalign file is empty

### If Subscript Nanosherlock is Executed Separately

The -e parameter of nanosherlock specifies the leading number of the error code. Default is 0.
- 019: Cannot basecall .slow5/.blow5 with guppy
- 020: Could not find raw data or unknown file format
- 021: Guppy basecalling failed
- 022: minimap2 mapping failed
- 022: mapping failed
- 023: Samtools indexing failed
- 024: f5c index failed
- 025: f5c eventalign failed
- 026: Could not find provided fastq files
- 027: f5c eventalign file is empty
</details>
25 changes: 9 additions & 16 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -10,16 +10,6 @@ for **linux-64 and osx-64**.
mamba create -n magnipore -c jannessp magnipore
conda activate magnipore
Alternatively you can create a conda environment using
the `conda_env.yml <conda.recipe/conda_env.yml>`__ and mamba.

.. code:: bash
conda install mamba
mamba env create -f conda/conda_env.yml
conda activate magnipore
git clone https://github.com/JannesSP/magnipore.git
If you want to basecall your ONT data you also need a Guppy version from
`Oxford Nanopore Technologies <https://community.nanoporetech.com>`__.

Expand Down Expand Up @@ -54,7 +44,7 @@ Conda Dependencies:
- matplotlib>=3.6.2
- numpy>=1.23
- scipy>=1.9
- minimap2>=2.24
- winnowmap>=2.0
- pandas>=1.5
- seaborn>=0.12
- psutil>=5.9
Expand Down Expand Up @@ -169,7 +159,7 @@ The .magnipore file is a TSV containing the following columns.
- signal_type : classification into “mod” for modification and “mut”
for mutation
- ref_1 : contig name of sample 1
- pos_1 : position in contig of sample 1
- pos_1 : position in contig of sample 1 (0-based)
- base_1 : base at the position of sample 1
- motif_1 : motif around the base at the position of sample 1
- signal_mean_1 : mean of the signal distribution at the position of
Expand Down Expand Up @@ -208,22 +198,24 @@ Error Codes Explanation
- 119: Cannot basecall other .slow5/.blow5 with guppy
- 120: Could not find raw data or unknown file format
- 121: Guppy basecalling failed
- 122: minimap2 mapping failed
- 122: mapping failed
- 123: Samtools indexing failed
- 124: f5c index failed
- 125: f5c eventalign failed
- 126: Could not find provided fastq files
- 127: f5c eventalign file is empty

Errors of second sample

- 219: Cannot basecall other .slow5/.blow5 with guppy
- 220: Could not find raw data or unknown file format
- 221: Guppy basecalling failed
- 222: minimap2 mapping failed
- 222: mapping failed
- 223: Samtools indexing failed
- 224: f5c index failed
- 225: f5c eventalign failed
- 226: Could not find provided fastq files
- 227: f5c eventalign file is empty

If Subscript Nanosherlock is Executed Separately
------------------------------------------------
Expand All @@ -234,8 +226,9 @@ error code. Default is 0.
- 019: Cannot basecall other .slow5/.blow5 with guppy
- 020: Could not find raw data or unknown file format
- 021: Guppy basecalling failed
- 022: minimap2 mapping failed
- 022: mapping failed
- 023: Samtools indexing failed
- 024: f5c index failed
- 025: f5c eventalign failed
- 026: Could not find provided fastq files
- 026: Could not find provided fastq files
- 027: f5c eventalign file is empty
235 changes: 0 additions & 235 deletions conda.recipe/conda_env.yml

This file was deleted.

Loading

0 comments on commit 95b4a82

Please sign in to comment.