Skip to content

Commit

Permalink
Merge pull request #76 from HarryHung/feature/unify-relational-operators
Browse files Browse the repository at this point in the history
Unify relational operators

Former-commit-id: 02b95d7
  • Loading branch information
HarryHung authored Oct 17, 2023
2 parents 7d97c13 + e77919e commit 9535b53
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 11 deletions.
2 changes: 1 addition & 1 deletion bin/get_assembly_qc.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ CONTIGS=$(awk -F'\t' '$1 == "# contigs (>= 0 bp)" { print $2 }' "$REPORT")
LENGTH=$(awk -F'\t' '$1 == "Total length" { print $2 }' "$REPORT")
DEPTH=$(echo "scale=2; $BASES / $LENGTH" | bc -l)

if [[ $CONTIGS -lt $QC_CONTIGS ]] && [[ $LENGTH -ge $QC_LENGTH_LOW ]] && [[ $LENGTH -le $QC_LENGTH_HIGH ]] && [[ "$(echo "$DEPTH >= $QC_DEPTH" | bc -l)" == 1 ]]; then
if [[ $CONTIGS -le $QC_CONTIGS ]] && [[ $LENGTH -ge $QC_LENGTH_LOW ]] && [[ $LENGTH -le $QC_LENGTH_HIGH ]] && [[ "$(echo "$DEPTH >= $QC_DEPTH" | bc -l)" == 1 ]]; then
ASSEMBLY_QC="PASS"
else
ASSEMBLY_QC="FAIL"
Expand Down
2 changes: 1 addition & 1 deletion bin/get_mapping_qc.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

COVERAGE=$(printf %.2f "$COVERAGE")

if [[ "$(echo "$COVERAGE > $QC_REF_COVERAGE" | bc -l)" == 1 ]] && [[ $HET_SNP -lt $QC_HET_SNP_SITE ]]; then
if [[ "$(echo "$COVERAGE >= $QC_REF_COVERAGE" | bc -l)" == 1 ]] && [[ $HET_SNP -le $QC_HET_SNP_SITE ]]; then
MAPPING_QC="PASS"
else
MAPPING_QC="FAIL"
Expand Down
2 changes: 1 addition & 1 deletion bin/get_taxonomy_qc.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ if [ -z "$TOP_NON_STREP_GENUS_PERCENTAGE" ]; then
TOP_NON_STREP_GENUS_PERCENTAGE="0.00"
fi

if [[ "$(echo "$PERCENTAGE > $QC_SPNEUMO_PERCENTAGE" | bc -l)" == 1 ]] && [[ "$(echo "$TOP_NON_STREP_GENUS_PERCENTAGE <= $QC_TOP_NON_STREP_GENUS_PERCENTAGE" | bc -l)" == 1 ]]; then
if [[ "$(echo "$PERCENTAGE >= $QC_SPNEUMO_PERCENTAGE" | bc -l)" == 1 ]] && [[ "$(echo "$TOP_NON_STREP_GENUS_PERCENTAGE <= $QC_TOP_NON_STREP_GENUS_PERCENTAGE" | bc -l)" == 1 ]]; then
TAXONOMY_QC="PASS"
else
TAXONOMY_QC="FAIL"
Expand Down
16 changes: 8 additions & 8 deletions doc/workflow.drawio.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 9535b53

Please sign in to comment.