-
Notifications
You must be signed in to change notification settings - Fork 41
Suggested parameters for bam filtering #76
Copy link
Copy link
Open
Description
Hey,
I have been experimenting with some of my datasets and I have found that filtering the bam files prior to SNP calling not only reduces the number of SNPs which come out of freebayes, but also reduces the filtering needed to remove artifacts from my data. Using bamtools filter I remove
- reads not properly paired
- reads on secondary alignments
- Mapping quality less than a given value
I think if you added this as a module before freebayes, then people could add the filters they wanted in a filter script if they wanted to use it.
Something like:
if [[ $FILTER = "yes" ]]; then
if [ -z filter.txt ]; then
echo "Please provide the bam filters"
exit 1
fi
bamtools filter -script filter.txt -in cat-RRG.bam -out cat-RRG_filter.bam;
mv cat-RRG_filter.bam cat-RRG.bam
fi
Then filter.txt scripts could be something like this:
{
"isPrimaryAlignment" : "true",
"isProperPair" : "true",
"mapQuality" : ">=40"
}
according to the bamtools filter manual.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels