<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def add_measurement(self, exp_name, meas_num, spec_name=None, er_data=None, pmag_data=None):
 """ Find actual data object for specimen. Then create a measurement belonging to that specimen and add it to the data object """

        specimen = self.find_by_name(spec_name, self.specimens)
        measurement = Measurement(exp_name, meas_num, specimen, er_data)
        self.measurements.append(measurement)
        return measurement