Skip to content

Instantly share code, notes, and snippets.

View harmony-smith's full-sized avatar
🎵

Harmony Smith harmony-smith

🎵
View GitHub Profile
@harmony-smith
harmony-smith / plot-skyline.R
Last active December 2, 2025 22:54 — forked from ArtPoon/plot-skyline.R
Generate a Bayesian skyline plot from BEAST log files using R
require(ape)
#' get.intervals
#'
#' Scan through BEAST tree log line-by-line and parse each
#' Newick string to retrieve the coalescent intervals
#'
#' @param treefile: (character) relative or absolute path to trees log file
#' @return List containing objects of class coalescentIntervals (ape) keyed
#' by state (MCMC step number)