add additional argument to only use selected barcodes