def update_frame(self, key, ranges=None, element=None):
        """
        Set the plot(s) to the given frame number.  Operates by
        manipulating the matplotlib objects held in the self._handles
        dictionary.

        If n is greater than the number of available frames, update
        using the last available frame.
        """
        reused = isinstance(self.hmap, DynamicMap) and self.overlaid
        if not reused and element is None:
            element = self._get_frame(key)
        elif element is not None:
            self.current_key = key
            self.current_frame = element

        if element is not None:
            self.param.set_param(**self.lookup_options(element, 'plot').options)
        axis = self.handles['axis']

        axes_visible = element is not None or self.overlaid
        axis.xaxis.set_visible(axes_visible and self.xaxis)
        axis.yaxis.set_visible(axes_visible and self.yaxis)
        axis.patch.set_alpha(np.min([int(axes_visible), 1]))

        for hname, handle in self.handles.items():
            hideable = hasattr(handle, 'set_visible')
            if hname not in ['axis', 'fig'] and hideable:
                handle.set_visible(element is not None)
        if element is None:
            return

        ranges = self.compute_ranges(self.hmap, key, ranges)
        ranges = util.match_spec(element, ranges)

        max_cycles = self.style._max_cycles
        style = self.lookup_options(element, 'style')
        self.style = style.max_cycles(max_cycles) if max_cycles else style

        label = element.label if self.show_legend else ''
        style = dict(label=label, zorder=self.zorder, **self.style[self.cyclic_index])
        axis_kwargs = self.update_handles(key, axis, element, ranges, style)
        self._finalize_axis(key, element=element, ranges=ranges,
                            **(axis_kwargs if axis_kwargs else {}))
def update_frame ( self , key , ranges = None , element = None ) : reused = isinstance ( self . hmap , DynamicMap ) and self . overlaid if not reused and element is None : element = self . _get_frame ( key ) elif element is not None : self . current_key = key self . current_frame = element if element is not None : self . param . set_param ( ** self . lookup_options ( element , 'plot' ) . options ) axis = self . handles [ 'axis' ] axes_visible = element is not None or self . overlaid axis . xaxis . set_visible ( axes_visible and self . xaxis ) axis . yaxis . set_visible ( axes_visible and self . yaxis ) axis . patch . set_alpha ( np . min ( [ int ( axes_visible ) , 1 ] ) ) for hname , handle in self . handles . items ( ) : hideable = hasattr ( handle , 'set_visible' ) if hname not in [ 'axis' , 'fig' ] and hideable : handle . set_visible ( element is not None ) if element is None : return ranges = self . compute_ranges ( self . hmap , key , ranges ) ranges = util . match_spec ( element , ranges ) max_cycles = self . style . _max_cycles style = self . lookup_options ( element , 'style' ) self . style = style . max_cycles ( max_cycles ) if max_cycles else style label = element . label if self . show_legend else '' style = dict ( label = label , zorder = self . zorder , ** self . style [ self . cyclic_index ] ) axis_kwargs = self . update_handles ( key , axis , element , ranges , style ) self . _finalize_axis ( key , element = element , ranges = ranges , ** ( axis_kwargs if axis_kwargs else { } ) )
Set the plot(s) to the given frame number.  Operates by
        manipulating the matplotlib objects held in the self._handles
        dictionary.

        If n is greater than the number of available frames, update
        using the last available frame.