def bar(self, var: str, title: str='', label: str='') -> object:
    '\n        This method requires a character column (use the contents method to see column types)\n        and generates a bar chart.\n\n        :param var: the CHAR variable (column) you want to plot\n        :param title: an optional title for the chart\n        :param label: LegendLABEL= value for sgplot\n        :return: graphic plot\n        '
    code = (((('proc sgplot data=' + self.libref) + '.') + self.table) + self._dsopts())
    code += ((";\n\tvbar '" + var) + "'n")
    if (len(label) > 0):
        code += ((" / LegendLABEL='" + label) + "'")
    code += ';\n'
    if (len(title) > 0):
        code += (('\ttitle "' + title) + '";\n')
    code += 'run;\ntitle;'
    if self.sas.nosub:
        print(code)
        return
    ll = self._is_valid()
    if (not ll):
        html = self.HTML
        self.HTML = 1
        ll = self.sas._io.submit(code)
        self.HTML = html
    if (not self.sas.batch):
        self.sas.DISPLAY(self.sas.HTML(ll['LST']))
    else:
        return ll
This method requires a character column (use the contents method to see column types)
and generates a bar chart.

:param var: the CHAR variable (column) you want to plot
:param title: an optional title for the chart
:param label: LegendLABEL= value for sgplot
:return: graphic plot
def bar(self, var: str, title: str=, label: str=) -> object:
    '\n        This method requires a character column (use the contents method to see column types)\n        and generates a bar chart.\n\n        :param var: the CHAR variable (column) you want to plot\n        :param title: an optional title for the chart\n        :param label: LegendLABEL= value for sgplot\n        :return: graphic plot\n        '
    code = (((('proc sgplot data=' + self.libref) + '.') + self.table) + self._dsopts())
    code += ((";\n\tvbar '" + var) + "'n")
    if (len(label) > 0):
        code += ((" / LegendLABEL='" + label) + "'")
    code += ';\n'
    if (len(title) > 0):
        code += (('\ttitle "' + title) + '";\n')
    code += 'run;\ntitle;'
    if self.sas.nosub:
        print(code)
        return
    ll = self._is_valid()
    if (not ll):
        html = self.HTML
        self.HTML = 1
        ll = self.sas._io.submit(code)
        self.HTML = html
    if (not self.sas.batch):
        self.sas.DISPLAY(self.sas.HTML(ll['LST']))
    else:
        return ll