Linguist Martin Schweinberger has used base R to perform a sociolinguistic analysis of swear word use in Irish English. The data analyzed is from the Irish component of the International Corpus of English.
I’m particularly tickled by the fact that the script contains a set of regular expressions that define swear words. For instance
search.pattern2 <- c (" [A|a]rse [s|d]{0 ,1} ")
Turns out that while young women swear less than young men—the latter seem to go through a period of more intense swearing—by the time people get beyond 34, there’s gender harmony in the use of profanity.