Added doctests for all methods