def initialize_plot(self, ranges=None, plot=None, plots=None, source=None):
        # Get element key and ranges for frame
        element = self.hmap.last
        key = self.keys[-1]
        ranges = self.compute_ranges(self.hmap, key, ranges)
        ranges = util.match_spec(element, ranges)
        self.current_ranges = ranges
        self.current_frame = element
        self.current_key = key

        # Initialize plot, source and glyph
        if plot is None:
            plot = self._init_plot(key, element, ranges=ranges, plots=plots)
            self._init_axes(plot)
        self.handles['plot'] = plot

        # Get data and initialize data source
        empty = self.callbacks and self.callbacks.downsample
        data, mapping = self.get_data(element, ranges, empty)
        if source is None:
            source = self._init_datasource(data)
        self.handles['source'] = source

        properties = self._glyph_properties(plot, element, source, ranges)
        renderer, glyph = self._init_glyph(plot, mapping, properties)
        self.handles['glyph'] = glyph
        if isinstance(renderer, Renderer):
            self.handles['glyph_renderer'] = renderer

        # Update plot, source and glyph
        self._update_glyph(glyph, properties, mapping)
        if not self.overlaid:
            self._update_plot(key, plot, element)
        if self.callbacks:
            self.callbacks(self)
            self.callbacks.update(self)
        self._process_legend()
        self.drawn = True

        return plot
Add the edge weights of the input graph to the current one. Results in a
dataset/ETHPy150Open ioam/holoviews/holoviews/plotting/bokeh/element.py/ElementPlot.initialize_plot--crossover with--dataset/ETHPy150Open charanpald/APGL/apgl/graph/PySparseGraph.py/PySparseGraph.add