To discover why there was no preference for which electrode the reaction took place at, we consulted my physics supervisor, Dr. Robin Ball. He suggested this:

You should know that the capacitance between a sphere and infinity is proportional to the radius of the sphere. An analogous calculation gives the same result for the 'spreading resistance' between a spherical conductor and infinity through an ohmic medium. I doubt your experiment is ohmic, but nevertheless the moral should apply that resistance to current flow will be dominated by the near-electrode regions and by the more resistive of the two. If one contact gets fried (and tissue broken down) this could well switch with time.

He also provides a possible explanation as to why the gherkins and onions actually glow:

Onion (cooked) is the source of a yellow die (the standard one in ancient times!). Whether your experiment is producing this die in an excited state is pure speculation.

Dr. Robin Ball works for the Theory of Condensed Matter Group at the Cavendish Laboratory, Cambridge.