I don't understand the behavior of the built-in function pmatch (partial string matching).
The description provides the following example:
pmatch("m", c("mean", "median", "mode")) # returns NA instead of 1,2,3
but using:
pmatch("m", "mean") # returns 1, as I would have expected.
Could anybody explain to me this behavior?