shorah icon indicating copy to clipboard operation
shorah copied to clipboard

is shorah same as lofreq?

Open ibseq opened this issue 2 years ago • 4 comments

Hi all, does shorah algorithms follow the same principle as lofreq?

thanks Ibseq

ibseq avatar Aug 31 '22 06:08 ibseq

Not quite.

LoFreq is mostly done position wise:

  • It calls SNVs per position (in a way that is roughly reminiscent in how samtools' pileup and bcftools works).
  • It uses some additionnal heurisitc to increase the confidence of the results (it does more than a simple basecount).

ShoRAH at its core is a local haplotype caller, SNVs are a by-product of this:

  • it divides all the aligned reads into windows.
    • NOTE there is currently a bad interaction between this division into windows and multiplex PCR amplicon protocols (e.g.: ARTIC v4.1) causing to lose window. A new version fixing this should come in the comming months
  • within each window, ShoRAH clusters reads together.
    • logic is that real SNVs each coming from the same haplotype will cluster together
    • whereas sequencing error will always be randomly spread among the read and will not cluster (i.e.: no matter how the sampler creates clusters, the error will fail to group together).
  • in each window, local haplotypes are called from the consensus of each such cluster of reads
    • (this will "average-out" any sequencing error according to the model).
  • SNV are then called simply by comparing these local haplotype with the reference
    • (at that stage, sequencing errors have been eliminated by the clustering, any difference should be "true SNV" as far as the model is concerned).

DrYak avatar Sep 09 '22 15:09 DrYak

Hi thanks again. I’m aware that we can use a flag to specifically use lofreq instead of shorah to analyse the data, in that case which parameters from Lofreq are then chosen?

thanks ibseq

ibseq avatar Oct 06 '22 07:10 ibseq

The flag to select is in the section general, parameter snv_caller.

The parameter for lofreq are taken from the section lofreq (example), unlike the parameters of shorah wich are taken from section snv (example)

See the content of the file config/config.html in your local installation for a full reference of the configuration.

DrYak avatar Oct 06 '22 11:10 DrYak

thanks again, looking at the config file suggested for sars cov 2 it seems no parameters are used to custom lofreq . while I believe these can be added , does it imply that lofreq is run in default - see screenshot

thanks ibseq

Sent from Outlook for iOShttps://aka.ms/o0ukef


From: DrYak @.> Sent: Thursday, October 6, 2022 12:25 pm To: cbg-ethz/shorah @.> Cc: ibseq @.>; Author @.> Subject: Re: [cbg-ethz/shorah] is shorah same as lofreq? (Issue #87)

The flag to select is in the section general, parameter snv_caller.

The parameter for lofreq are taken from the section lofreq (examplehttps://github.com/cbg-ethz/pangolin/blob/6159461d926c677b80060e5c9fd2496cf6af6ffa/working/vpipe.config#L117), unlike the parameters of shorah wich are taken from section snv (examplehttps://github.com/cbg-ethz/pangolin/blob/6159461d926c677b80060e5c9fd2496cf6af6ffa/working/vpipe.config#L123)

See the content of the file config/config.html in your local installation for a full reference of the configuration.

— Reply to this email directly, view it on GitHubhttps://github.com/cbg-ethz/shorah/issues/87#issuecomment-1269851879, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AH76DQ6VZMAUEXUHOPRAJQTWB2ZI5ANCNFSM6AAAAAAQBBVSFE. You are receiving this because you authored the thread.Message ID: @.***>

ibseq avatar Oct 06 '22 13:10 ibseq