Add doc strings and fix spaces

@rocha @peter-fogg please review pep8/pylint cleanups