This closes #25, closes #23