How to subset a BAM by specific name?

Hi everyone,

I have a BAM file in the following format (some of the data).

I would like to subset my BAM via specific cell barcode sequences (e.g, AAAGAACCAGGACATG, AACCAACAGAGATTCA, GCCATTCTCACAGTGT) into a new BAM.

Is there any way to do so efficiently?

It would be great if someone knew how to do this.

Stay healthy.
Many thanks,

Miae

1 Like

Hi Miae

If you are just interested in a particular cell barcode, have you tried “Select lines that match an expression” (https://usegalaxy.eu/root?tool_id=Grep1), assuming your file is actually in SAM format.

Regards, Hans-Rudolf

1 Like

Hi Hans-Rudolf,

It worked (:D)
I am a beginner who has just started using Galaxy. I am getting a lot of help through Galaxy Help.
Thank you very much.

Miae

1 Like