milaboratory / mixcr

MiXCR is an ultimate software platform for analysis of Next-Generation Sequencing (NGS) data for immune profiling.
https://mixcr.com
Other
336 stars 79 forks source link

Long CDR3 sequences #1721

Closed Januaryyiyue closed 4 months ago

Januaryyiyue commented 4 months ago

I am using the analyze command with MiXCR version 4.6. I got the following CDR3 alpha clone: CCLKDTFLPDTMYWGSSKVFRNDACGSALTAQLFF This seems to be an artefact. How can I remove such clones (e.g., clones longer than 20aas) from my analysis? Especially from the .clns file, because I am also using the .clns file for postanalysis.

Thank you so much.

mizraelson commented 4 months ago

Hi, If you can export a list of clone IDs (excluding the IDs of the clones you want to filter out, for example, based on the length of the aaSeqCDR3) in a TSV file as a column of numbers, you can then run:

mixcr slice \
    --ids-file ids.tsv \
    input.clns \
    filtered.clns

filtered.clns will only contain the clones specified in the ids.tsv file.