An ecocline is a biological transition zone in which organisms of a given species exhibit gradual genetic differences due to such variables as latitude or elevation. We are interested in detecting locations in the genome-specifically, single nucleotide polymorphisms (SNPs)-where monotone changes in allele frequencies can be related to environmental variables in the ecocline. While there are existing methods to do this, we present here a new method that uses Bayes Factors to identify SNPs of interest. Our method offers several advantages. First, existing methods require genotyping of individuals, whereas ours permits the use of pooled data from multiple individuals, which is far cheaper to obtain. Second, our method avoids the assumption of Hardy-Weinberg equilibrium. Finally, our posterior distribution is a polynomial, allowing exact inference without the use of MCMC.