reduced variance

The main intent is to prevent models with 0 modes of variation, which leads to a crash when using the model afterwards.
I made it conservative: keep the modes to reach at least the requested percentage of variance.
Feel free to change it to 'at least 1 mode' if you prefer.