def add_visualization(self, visualization, size_x=6, size_y=3, col=0, row=0):
        """
        Adds the visualization to the dashboard. Leave col and row = 0 for automatic placement of the visualization.
        Visualizations are placed on a grid with 12 columns and unlimited rows.
        :param visualization: previously loaded visualization
        :param size_x width of the panel
        :param size_y height of the panel
        :param col 1-based column of the top left corner, leave 0 for automatic placement
        :param row 1-based row of the top left corner, leave 0 for automatic placement
        :return: newly created panel or None
        """
        new_panel_index = self.get_max_index()+1
        if col and row:
            new_panel = {
                'col': col, 'row': row,
                'size_x': size_x, 'size_y': size_y,
                'panelIndex': new_panel_index,
                'type': 'visualization',
                'id': visualization.id
            }
            self.panels.append(new_panel)
            return new_panel
        else:
            new_panel = append_panel(self.panels, size_x, size_y)
            if new_panel:
                new_panel['id'] = visualization.id
                new_panel['panelIndex'] = new_panel_index
                new_panel['type'] = 'visualization'
                return new_panel