So say,
x <- c("aa/bb:cc/dd", "aa/cc:cc/dd", "aa/cc:aa/ee")
y <- c("aa")
now I need to count the substring "aa" along the row it should give me the count irrespective if it is present as two times. eg: aa= 3 not 4
So say,
x <- c("aa/bb:cc/dd", "aa/cc:cc/dd", "aa/cc:aa/ee")
y <- c("aa")
now I need to count the substring "aa" along the row it should give me the count irrespective if it is present as two times. eg: aa= 3 not 4