Docstrings and clean up! Proud of this beaut