refactor the way how samples are choosen. Add article example.