Fix up doc strings, simplify some functions, etc.
Merge pull request #288 from ketch/general_maintenance

Fix up doc strings, simplify some functions, etc.