-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
refdb_clean_seq_crop_primers returns NA if one primer is not found:
repex:
primer_F <- paste0(rep("A",20), collapse = "")
primer_R <- paste0(rep("T",20), collapse = "")
SEQ <- paste0(rep("CG",10), collapse = "")
seq_w_F <- paste0(primer_F, SEQ, collapse = "")
seq_w_R <- paste0(SEQ, primer_R, collapse = "")
seq_FR <- paste0(primer_F, SEQ, primer_R, collapse = "")
test <-
tibble(primer = c("seq_w_F",
"seq_w_R",
"seq_FR",
"seq_noP"),
sequence = c(seq_w_F,
seq_w_R,
seq_FR,
SEQ)) %>%
refdb_set_fields(sequence = "sequence")
refdb_clean_seq_crop_primers(test,
primer_F,
primer_R,
include_primers = F)
this results in
primer sequence
<chr> <DNA>
1 seq_w_F NA
2 seq_w_R NA
3 seq_FR CGCGCGCGCGCGCGCGCGCG
4 seq_noP NA
I think it should default (or have the option) to crop the primers if they are found but to keep it if none or only one is found.
PS. I realize the the function is a wrapper for bioseq::seq_crop_pattern where this is the documented behavior...
Metadata
Metadata
Assignees
Labels
No labels