Improve documentation

* document some private functions
* fix documentation of learning curve and example