Hi!
Thank you for your suggestion!
I tried !%in% as here in the example:
library(dplyr)
df <- data.frame(
stringsAsFactors = FALSE,
Index = c(27L, 22L, 17L, 25L, 12L, 3L),
Filename = c("f99Ogoelong","f99Dliit",
"f99Akur","f99Dreep","f00Jfuan","c00ANyouth3"),
Genre = c("Traditional narrative (with singing)","Traditional narrative","Traditional narrative",
"Traditional narrative","Traditional narrative",
"Conversation"),
duration = c("0:11:24","0:08:57","0:05:26",
"0:07:23","0:10:04","0:06:29"),
Wordcount = c(1840L, 1413L, 1302L, 1226L, 1156L, 1153L)
)
G$Index <- as.character(G$Index)
narr <- G %>%
filter(Genre == "Traditional narrative") %>%
filter(Index !%in% c("12","21","20","16","23","11","13")) %>%
arrange(desc( factor(Wordcount)))
It failed either, the error is
Error: unexpected '!' in:
" filter(Genre == "Traditional narrative") %>%
filter(Index !"
Is that due to the library? 