fix function name; add docstring
better docstrings
remove unused functions