Added some more functionality and documentation