if I have a vector
x <- c("aa/bb","cc/aa","aa/dd", "bb/cc")
I want to get a output for specif substrings such as for "aa" and "bb":
aa = 3
bb = 2
This frequency can be calculated of irrespective of the position. Kindly let me know do we have a function for this or we need to write a separate function.
Thanks in advance.