#!/bin/bash if (( $# < 1 )); then echo "Print number of unique unknowntags" echo "Usage: $0 ./block-I/02-inspect/dataFile" exit fi grep X $1 | cut -d',' -f8 | sort | uniq | wc -l # if (( "$#" < 2 )); then # echo "Usage: this data.csv newtagFile" # echo "1. searches for unkown tags ('X') and saves them in a list named unknownTags" # echo "2. compares these tags, with the tags from tagFile" # echo "If anything matches, the beetle/tag must've been in the unit!" # exit 1 # fi # while IFS= read -r line # do # grep "$line" $unknownTags # done < "$2"