def format(self, value):
        """Set the format type.
            Allowed charts are: count or percentage

            Args:
                value (str): format type.

            Raises:
                ValueError: Not a valid format. Must be count or percentage.
        """
        if value not in ["count", "percentage"]:
            raise ValueError("Not a valid format. Must be count or percentage")

        self.options["format"] = value
dataset/ETHPy150Open stitchfix/pyxley/pyxley/charts/mg/graphic.py/Graphic.format/original