Entering edit mode
I have a DNA sequence files and many sequences start like this "CCCATGCAGACATAGTG" or "CTCCATGCAGACATAGTG" and I have a tag sequence which is "ATGCA". I want to remove all the "ATGCA" as well as "CC" or "CTC" before that. So the final product will be "GACATAGTG". Does anyone know any R function can do that? I tried trimLRPatterns in biostrings but it does not work since it only trim from the end but not within the sequence. Please let me know if you have any solution to that. Thanks.