def to_html(self, classes=None, notebook=False, border=None):
        """
        Render a DataFrame to a html table.

        Parameters
        ----------
        classes : str or list-like
            classes to include in the `class` attribute of the opening
            ``<table>`` tag, in addition to the default "dataframe".
        notebook : {True, False}, optional, default False
            Whether the generated HTML is for IPython Notebook.
        border : int
            A ``border=border`` attribute is included in the opening
            ``<table>`` tag. Default ``pd.options.html.border``.

            .. versionadded:: 0.19.0
         """
        from pandas.io.formats.html import HTMLFormatter, NotebookFormatter
        Klass = NotebookFormatter if notebook else HTMLFormatter
        html = Klass(self, classes=classes, border=border).render()
        if hasattr(self.buf, 'write'):
            buffer_put_lines(self.buf, html)
        elif isinstance(self.buf, str):
            with open(self.buf, 'w') as f:
                buffer_put_lines(f, html)
        else:
            raise TypeError('buf is not a file name and it has no write '
                            ' method')