Question: (Closed) convert gz to bam
0
gravatar for thioubmouhamadou
20 months ago by
thioubmouhamadou0 wrote:

I have a problem converting a gz file into a bam file. How can I do this using the samtools library. Thank you

genome • 1.1k views
ADD COMMENTlink modified 20 months ago • written 20 months ago by thioubmouhamadou0
2

Brief Reminder On How To Ask A Good Question

Please spend some time reading/searching this forum. If you still need assistance then improve your question by putting some effort into it and showing us what you have tried to achieve your goal.

ADD REPLYlink modified 20 months ago • written 20 months ago by GenoMax92k
2

gz is a common file extension used for files that are either gzip-compressed or bgzip-compressed. As such, it denotes a file format. bam is a file format (and also a file extension, but a file format first) that stores reference-aligned or unaligned reads. You can get from one level of information content to another, but you cannot "convert" between two different paradigms without an understanding of the fundamentals.

ADD REPLYlink written 20 months ago by _r_am31k

I have several gz files. And I want to compress them in bam with C code.

ADD REPLYlink written 20 months ago by thioubmouhamadou0
1

This is like saying "I have several edible items. And I want to compress them to sandwich using metal".

Not all edible items can be made into a sandwich and you don't need to start from metal to get to a tool that can make a sandwich from specific, compatible edible items.

ADD REPLYlink written 20 months ago by _r_am31k

can you post one entire file name here? what comes before the .gz?

ADD REPLYlink written 20 months ago by Friederike6.5k

Please use ADD COMMENT/ADD REPLY when responding to existing posts to keep threads logically organized. SUBMIT ANSWER is for new answers to original question.

Is this a homework/assignment question? If it is you should clarify that. Are these sequence data files or something else?

Please check what @RamRS posted above for reference.

ADD REPLYlink modified 20 months ago • written 20 months ago by GenoMax92k

Why do you want to use C?

ADD REPLYlink written 20 months ago by Joe18k

Friederike . For example chr1.gz i use the sametools library

ADD REPLYlink written 20 months ago by thioubmouhamadou0

Please stop adding answers unless you're answering the top level question.

ADD REPLYlink written 20 months ago by _r_am31k

What does chr1.gz contain? Please edit your question and add a significant amount of relevant detail so your question can be reopened.

ADD REPLYlink modified 20 months ago • written 20 months ago by _r_am31k

Hello thioubmouhamadou!

We believe that this post does not fit the main topic of this site.

OP keeps adding answers. Also, question too vague

For this reason we have closed your question. This allows us to keep the site focused on the topics that the community can help with.

If you disagree please tell us why in a reply below, we'll be happy to talk about it.

Cheers!

ADD REPLYlink written 20 months ago by _r_am31k
Please log in to add an answer.
The thread is closed. No new answers may be added.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.3.0
Traffic: 1847 users visited in the last hour