pep8ified and reduced complexity of methods
Pepified, added qvals