Skip to content
New issue

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

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

Already on GitHub? # to your account

Cluster alignements to reproduce #1649

Open
Lipinski-B opened this issue Jan 30, 2025 · 1 comment
Open

Cluster alignements to reproduce #1649

Lipinski-B opened this issue Jan 30, 2025 · 1 comment

Comments

@Lipinski-B
Copy link

Hello,

I had the opportunity to test the "cluster alignments EXPERIMENTAL"'option in IGV version 2.19.1, and I found it very interesting to use.

My question is :
Is there a way to reproduce it in command line from a bam file, and to split clusters results by several FASTQ?
Or is there a way to know better how does the clustering work, directly from the bam?

Many thanks in advance for your answer.
Best regards,
Boris

@jrobinso
Copy link
Contributor

Hi,

No it is not possible to do this from the command line with IGV. Its been years since this was implemented and I don't recall all the details, but the code is here https://github.com/igvteam/igv/blob/main/src/main/java/org/broad/igv/sam/ClusterUtils.java.

In brief, from memory, it goes something like this.

  1. Determine SNP positions for the region in view. I think the rule for a SNP position is the same rule used to assign color to the coverage track, that is positions with a count of mismatch to reference > some threshold
  2. Assign labels to each alignment from the base values at the snp position
  3. Compute pairwise distance between each alignment label. I don't recall the metric here, its in the code, but some kind of string similarity metric.
  4. Cluster alignments into N classes based on the distances from 3. N is supplied by the user.

Indels are not considered.

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

No branches or pull requests

2 participants