Added examples and improved documentation.