updated docstrings and minor changes