2 # Copyright (C) The Lightning Authors. All rights reserved.
4 # SPDX-License-Identifier: AGPL-3.0
17 for count in ${counts[@]}; do
18 rsid=`cut -d' ' -f5 $count`
19 gnomad=`cut -d' ' -f10 $count`
20 total=`cut -d' ' -f2 $count`
21 allrsid=`echo $(($allrsid + $rsid))`
22 allgnomad=`echo $(($allgnomad + $gnomad))`
23 alltotal=`echo $(($alltotal + $total))`
25 rsidpercentage=`awk -v n="$allrsid" -v d="$alltotal" 'BEGIN {print n/d*100}'`
26 gnomadpercentage=`awk -v n="$allgnomad" -v d="$alltotal" 'BEGIN {print n/d*100}'`
28 echo "overall: $alltotal total variants, $allrsid variants ($rsidpercentage%) have rsID, $allgnomad variants ($gnomadpercentage%) have gnomad AF"