Add docstrings to all helper functions; make docstrings more uniform