Refactored DataSet constructor