Is it possible to add additional sample ID's to the reads in a fastq file whilst demultiplexing.
I have pooled sequences from 95 wells for each plate and primer sequences determines the well ID. So currrently, after demultiplexing, I have a script that takes in the input fastq file, reads the first 30 basepairs whilst looking for "NN" and then for "Y" and converts the primer sequences to degenerate bases to get the right primer set. This primer set then helps assign well id. However to make the process workflow simpler, I would like this to happen right at the demultiplexing stage. Any insight will be most helpful.
i.e. From read in fastq file
>C04 12:86:000000000-BCB57:1:1101:17394:1866 CACGGTTGACTCAGCCCTTGACCAGGCACCTCGAATTCCACAGGGC
Here C04 is my well ID. I have a primerset Sequence file given by Name, type, chain, index and sequence. So, CO4 id is like so