RESUMEN
Local adaptation to different environments can promote mating isolation--either as an incidental by-product of trait divergence, or as a result of selection to avoid maladaptive mating. Numerous recent empirical examples point to the common influence of divergent natural selection on speciation based largely on evidence of strong pre-mating isolation between populations from different habitat types. Accumulating evidence for natural selection's influence on speciation is therefore no longer a challenge. The difficulty, rather, is in determining the mechanisms involved in the progress of adaptive divergence to speciation once barriers to gene flow are already present. Here, we present results of both laboratory and field experiments with Trinidadian guppies (Poecilia reticulata) from different environments, who do not show complete reproductive isolation despite adaptive divergence. We investigate patterns of mating isolation between populations that do and do not exchange migrants and show evidence for both by-product and reinforcement mechanisms depending on female ecology. Specifically, low-predation females discriminate against all high-predation males thus implying a by-product mechanism, whereas high-predation females only discriminate against low-predation males from further upstream in the same river, implying selection to avoid maladaptive mating. Our study thus confirms that mechanisms of adaptive speciation are not necessarily mutually exclusive and uncovers the complex ecology-geography interactions that underlie the evolution of mating isolation in nature.