A plum was an edible fruit from Earth that was grown on trees.
Nancy Crater gave Leonard McCoy the nickname "Plum" during their brief relationship in the 2250s. The M-113 creature impersonating Nancy also referred to McCoy as "Plum", when the doctor was part of the USS Enterprise landing party to planet M-113 in 2266. (TOS: "The Man Trap")
The novel A Choice of Catastrophes mentions that the nickname was given due to a mishap on McCoy's part with a (presumably plum-flavored) slushie.
The 1960 song "The Best Is Yet to Come", sung by Vic Fontaine and Benjamin Sisko, referenced picking a plum from a tree. (DS9: "Badda-Bing, Badda-Bang")