fixed a bug in model selection
added documentation