Major refactor

Closes issues #2 and #3.
Release 0.2.0