Some improvements to documentation and function usage.