fix bug in profile_data by when specifying profile_number