Added documentation for individual functions