ENH: doc and test
Automatic style corrections courtesy of autopep8