I'm trying to tabulate phones (characters) occurrences in a string, but diacritics are tabulated as characters on their own. Ideally, I have a wordlist in International Phonetic Alphabet, with a fair amount of diacritics and several combinations of them with base characters. I give here a MWE with just one word, but the same goes with list of words and more types of combinations.
> word <- "n̥ana" # word constituted by 4 phones: [n̥],[a],[n],[a]
> table(strsplit(word, ""))
̥ a n
1 2 2
But the wanted result is:
a n n̥
2 1 1
How can I manage to get this kind of result?