Comments (2)
Hi Mathieu,
Thanks for your feedback.
NextGenMap does take the -i parameter into account. But it is perfectly possible that you simply don't get alignments with an identity below 0.75. Therefore, changing the -i option from 0.65 to 0.55 or 0.75 won't have any effect. If you try changing it to 0.95 you should see an effect.
If you want to check the identity distribution for your dataset(s) you could do the following:
#Map without identity threshold
ngm -r <ref> -q <query> -i 0.0 -o ngm-output.sam
#Extract identity values from sam file
grep -oP "XI:f:[0-9.]+" ngm-output.sam | cut -d ":" -f 3 > ngm-identity-dist.csv
In R:
identDist = read.table("ngm-identity-dist.csv")
hist(identDist$V1)
As an example I attached two images. One from running NextGenMap (version 0.4.10) with -i 0.0 and one for -i 0.85 (both with local alignment).
Please also keep in mind that per default NextGenMap computes a local alignment. So if for example the first 10 bases of a read don't match the reference (but the rest of the read does) NextGenMap will clip the first 10 bases and only align the rest of the read. Thus, the 10 bases that don't match won't be considered for the identity computation.
To prevent NextGenMap from mapping only short parts of the reads we introduced the -R/--min-residues parameters and set the default value to 50% of the read length. Thus, alignments that contain less then 50% of the read will be discarded. So if you aim for a more stringent mapping you can increase this parameter.
If you definitely want the whole read to be aligned you could also tell NextGenMap to compute end-to-end (semi-global) alignments by using the -e/--end-to-end parameter.
I hope this solves your problem. For the case that you have alignments with an identity < 0.75 please report back and include how you run NextGenMap (all parameters) and information about your dataset (read length, etc.)
Best,
Philipp
from nextgenmap.
Dear Philipp,
Thanks for this very detailed reply.
My mistake : I indeed didn't dig enough into my data and, tough rather being counter-intuitive regarding my samples, it happened that very few alignments show an identity score below 0.75.
Distribution of identity scores with the default -i parameter value (-i = 0.65) :
summary(ciA_k27ac_ngm_k10_identity$V1)
Min. 1st Qu. Median Mean 3rd Qu. Max.
0.7234 0.8810 0.9268 0.9210 0.9592 1.0000
Distribution of identity scores with -i = 0.75 :
summary(ciA_k27ac_ngm_k10_i75_identity$V1)
Min. 1st Qu. Median Mean 3rd Qu. Max.
0.7500 0.8810 0.9268 0.9210 0.9592 1.0000
The -i parameter filtering in NGM indeed works properly.
Sorry for this wrong alert and thanks again for your time,
Mathieu
from nextgenmap.
Related Issues (20)
- Error: NVIDIA Platform not found
- Incorrect permissions after install HOT 3
- Provide an entrypoint in the docker container
- The docker container does not specify which version of ubuntu is used
- Not able to view sam file ? HOT 2
- Question about indexing the reference genome HOT 3
- -h should return 0, not 1
- Add --version switch
- Now packaged in Homebrew Science HOT 2
- Massive discrepency between proper pair counts between NGM and bwa HOT 2
- paired-end mapping FF orientation
- NGM: Header does not match the data HOT 10
- [PREPROCESS] Max. k-mer frequency set so HOT 2
- NextGenMap for bisulfite data and methylation calling HOT 3
- Tag handling with --keep-tags creates invalid SAM output HOT 1
- Error: program build failure (-11) occurs when running NextGenMap with Docker HOT 2
- @RG headers not being passed on to BAM
- -t/--threads cmd line parsing error
- Increase GPU load (AMD Graphic card) ? HOT 2
- What does the --slam-seq parameter do? HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from nextgenmap.