R programming in phylogenetics and evolution

This dissertation addresses the application of the statistical computing language R in the study of evolution and diversification of plants. The topics included range from the worldwide historical biogeography of the cucurbit family and the phylogenetic composition of the Mediterranean Oxalis flora in central Chile to the interplay between population genetics and climatic niche evolution in four Horde- um clades in the Americas. In these studies, I drew on existing methods in R and on java and C programs that could be easily integrated with R. Whenever necessary, I created additional software available in four new R packages. R's features, e.g., intersystem-interfaces, extensibility, reproducibility and advanced graphical capability, proved well suited for evolutionary and phylogenetic research. My coauthors and I addressed the history of Cucurbitaceae, one of the most economically important families of plants, using a multi-gene phylogeny for 114 of the 115 genera and 25 per cent of the 960 species. Worldwide sampling was achieved by using specimens from 30 herbaria. Results reveal an Asian origin of Cucurbitaceae in the Late Cretaceous, followed by the repeated spread of lineages into the African, American and Australian continents via transoceanic long-distance dispersal (LDD). North American cucurbits stem from at least seven range expansions of Central and South American lineages; Madagascar was colonized 13 times, always from Africa; Australia was reached 12 times, apparently always from Southeast Asia. Overall, Cucurbitaceae underwent at least 43 successful LDD events over the past 60 Myr, which would translate into an average of seven LDDs every 10 Myr. These and similar findings from other angiosperms stress the need for an increased tapping of museum collections to achieve extensive geographical sampling in plant phylogenetics. The second study focused on the interplay of population demography with the evolution of ecological niches during or after speciation in Hordeum. While large populations maintain a high level of standing genetic diversity, gene ow and recombination buffers against fast alterations in ecological adaptation. Small populations harbor lower allele diversity but can more easily shift to new niches if they initially survive under changed conditions. Thus, large populations should be more conservative regarding niche changes in comparison to small populations. My coauthors and I used environmental niche modeling together with phylogenetic, phylogeographic and population genetic analyses to infer the correlation of population demography with changes in ecological niche dimensions in 12 diploid Hordeum species from the New World, forming four monophyletic groups. Our analyses found both shifts and conservatism in certain niche dimensions within and among clades. Speciation due to vicariance resulted in three species with no pronounced climate niche differences, while species originating due to long-distance dispersals or otherwise encountering genetic bottlenecks mostly revealed climate niche shifts. Niche convergence among clades indicates a niche-filling pattern during the last 2 Myr in South American Hordeum. We provide evidence that species that did not encounter population reductions mainly show ecoclimatic niche conservatism, while major niche shifts have occurred in species that have undergone population bottlenecks. Our analyses allow the conclusion that population demography influences adaptation and niche shifts or conservatism in South American Hordeum species. Finally, I studied the phylogenetic composition of Oxalis flora of Mediterranean zone of Chile by asking whether in such a species-rich clade xerophytic adaptations arose in parallel, at different times, or simultaneously. Answering this type of question has been a major concern of evolutionary biology over the past few years, with a growing consensus that lineages tend to be conservative in their vegetative traits and niche requirements. Combined nuclear and chloroplast DNA sequences for 112 species of Oxalidales (4900 aligned nucleotides) were used for a fossil-calibrated phylogeny that includes 43 of the 54 species of Chilean Oxalis, and species distribution models (SDMs) incorporating precipitation, temperature, and fog, and the phylogeny were used to reconstruct ancestral habitat preferences, relying on likelihood and Bayesian techniques. Since uneven collecting can reduce the power of SDMs, we compared 3 strategies to correct for collecting effort. Unexpectedly, the Oxalis flora of Chile consists of 7 distant lineages that originated at different times prior to the last Andean uplift pulse; some had features preadapting them to seasonally arid or xeric conditions. Models that incorporated fog and a `collecting activity surface' performed best and identified the Mediterranean zone as a hotspot of Oxalis species as well as lineage diversity because it harbors a mix of ancient and young groups, including insuficiently arid-adapted species. There is no evidence of rapid adaptive radiation.