Fix issue #341 (github).
Add test case for #341 (github).
Variable rename and illustration.
Merge pull request #348 from cwahbong/select-cr-fix

Fix issue #341 (github).