def write_hdf5_flag(flag, output, path=None, **kwargs):
<EOL>if path is None:<EOL><INDENT>path = flag.name<EOL><DEDENT>if path is None:<EOL><INDENT>raise ValueError("<STR_LIT>"<EOL>"<STR_LIT>"<EOL>"<STR_LIT>")<EOL><DEDENT>return write_hdf5_dict({path: flag}, output, **kwargs)<EOL>
Write a `DataQualityFlag` to an HDF5 file/group