Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

unmapped vs mapped in covplot #117

Open
shoyosato opened this issue Nov 12, 2021 · 6 comments
Open

unmapped vs mapped in covplot #117

shoyosato opened this issue Nov 12, 2021 · 6 comments

Comments

@shoyosato
Copy link

I produced a covplot for my data and it shows 51.57% unmapped reads. This number does not match the mapped reads info from my .cov or .json. Are these supposed to be congruent? I was expecting the no-hits blobs to be larger in the blobplot to assess where my organism's coverage/gc content fall. I am wondering if this 51.57% should be part of the no-hits blobs. Thank you!

here is my covplot:

epibro_blob blobDB json bestsum phylum p8 span 100 blobplot read_cov bam0

Here are the first four lines from my .cov file:

## 1.1.1
## Total Reads = 22276300
## Mapped Reads = 22265834
## Unmapped Reads = 10466

and some info from the end of the .json:

"reads_total": 22276300, "reads_mapped": 22265834, "reads_unmapped": 0, 
@dtusso2020
Copy link

Hello shoyosato

Did you solve your problem? The same happens to me.

@shoyosato
Copy link
Author

Hey Diana!

Ya, it seemed to be an issue with long reads for me. I originally mapped the long reads back to the LR assembly to calculate coverage. I reran with short read data and the mapped bar bumped up to 98.6%. Sorry that the fix didn't really solve the root of problem....

@mrmrwinter
Copy link

I'm also having this issue, also when using long reads. Is there a way to change the mapping module to minimap2, vulcan, or something similar?

In the meantime I will try fragmenting the long reads and seeing if they map better

@DRL
Copy link
Owner

DRL commented Jun 17, 2022

Blobtools only parses the BAM file ... see here for a approximate description how it works (actually done via pysam now, but should be the same filters than samtools output)

For those people seeing weird things, check how your mapper made the alignments. Most likely there are multiple alignments or weird SAM flags for a given long read which then inflates numbers weirdly.

@Sabrin2020
Copy link

Sabrin2020 commented Oct 14, 2022

How to do the same plots please with blobtools2?

@magrgic
Copy link

magrgic commented Mar 1, 2024

Hello,
I have a similar issue when using long reads; did anyone manage to get around it?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants