Fixed a bug where data is deleted in generic.bagging
Refactored .suppress.warings and .restore.warnings