def to_json(self):
a_per = self.analysis_period.to_json() if self.analysis_period else None<EOL>return {'<STR_LIT>': self.data_type.to_json(),<EOL>'<STR_LIT>': self.unit,<EOL>'<STR_LIT>': a_per,<EOL>'<STR_LIT>': self.metadata}<EOL>
Return a header as a dictionary.