Implemented an rudimentary interface for pyplot, refactored code
Implemented toDict in BwStats