Misc changes, closes #53.