Skip to content

Commit

Permalink
[prune] Make pruneCrossAllelic more conservative
Browse files Browse the repository at this point in the history
  • Loading branch information
tanghaibao committed Jul 14, 2019
1 parent 6825277 commit f6e12fb
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions prune.go
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ func (r *Pruner) Run() {
r.edges = parseDist(r.PairsFile)
r.alleleGroups = parseAllelesFile(r.AllelesFile)
r.pruneAllelic()
// r.pruneCrossAllelic()
r.pruneCrossAllelic()
newPairsFile := RemoveExt(r.PairsFile) + ".prune.txt"
writePairsFile(newPairsFile, r.edges)
}
Expand Down Expand Up @@ -118,7 +118,7 @@ func (r *Pruner) pruneCrossAllelic() {
for i, edge := range r.edges {
aBestScore := getScore(edge.at, edge.bt, ctgToAlleleGroup, scores)
bBestScore := getScore(edge.bt, edge.at, ctgToAlleleGroup, scores)
if edge.nObservedLinks < aBestScore || edge.nObservedLinks < bBestScore {
if edge.nObservedLinks < aBestScore && edge.nObservedLinks < bBestScore {
r.edges[i].label = fmt.Sprintf("cross-allelic(%d|%d)", aBestScore, bBestScore)
pruned++
prunedLinks += edge.nObservedLinks
Expand Down

0 comments on commit f6e12fb

Please sign in to comment.