added set_data method