Updated docstrings and readability.