added docs to readme and updated example