neuroprob/utils/plot.py
def add_colorbar(figax, image, cbar_outline=False, cbar_ori='vertical', cbar_fontsize=12, 
                 cbar_pad=20, ticktitle=None, ticks=None, ticklabels=None, cbar_format=None):
    """
    Adds a colorbar object to the axis.
    
    :param string cbar_format: cbar label formatting, scientific mode '%.1e'
    """
    fig, ax = figax
    if cbar_ori == 'vertical':
        rot = 270
    else:
        rot = 0

    cbar = fig.colorbar(image, cax=ax, orientation=cbar_ori, format=cbar_format)
    cbar.outline.set_visible(cbar_outline)

    if ticks is not None:
        cbar.set_ticks(ticks)
    if ticklabels is not None:
        cbar.set_ticklabels(ticklabels)
    if ticktitle is not None:
        cbar.ax.get_yaxis().labelpad = cbar_pad
        cbar.ax.set_ylabel(ticktitle, rotation=rot, fontsize=cbar_fontsize)

    Adds a colorbar object to the axis.
    
    :param string cbar_format: cbar label formatting, scientific mode '%.1e'
    
Adds a colorbar object to the axis.
Adds a colorbar object to the axis .
def add_colorbar(figax, image, cbar_outline=False, cbar_ori='vertical', cbar_fontsize=12, 
                 cbar_pad=20, ticktitle=None, ticks=None, ticklabels=None, cbar_format=None):
    fig, ax = figax
    if cbar_ori == 'vertical':
        rot = 270
    else:
        rot = 0
    cbar = fig.colorbar(image, cax=ax, orientation=cbar_ori, format=cbar_format)
    cbar.outline.set_visible(cbar_outline)
    if ticks is not None:
        cbar.set_ticks(ticks)
    if ticklabels is not None:
        cbar.set_ticklabels(ticklabels)
    if ticktitle is not None:
        cbar.ax.get_yaxis().labelpad = cbar_pad
        cbar.ax.set_ylabel(ticktitle, rotation=rot, fontsize=cbar_fontsize)
def add_colorbar ( figax , image , cbar_outline = False , cbar_ori = 'vertical' , cbar_fontsize = 12 , cbar_pad = 20 , ticktitle = None , ticks = None , ticklabels = None , cbar_format = None ) : fig , ax = figax if cbar_ori == 'vertical' : rot = 270 else : rot = 0 cbar = fig . colorbar ( image , cax = ax , orientation = cbar_ori , format = cbar_format ) cbar . outline . set_visible ( cbar_outline ) if ticks is not None : cbar . set_ticks ( ticks ) if ticklabels is not None : cbar . set_ticklabels ( ticklabels ) if ticktitle is not None : cbar . ax . get_yaxis ( ) . labelpad = cbar_pad cbar . ax . set_ylabel ( ticktitle , rotation = rot , fontsize = cbar_fontsize )
Adds a colorbar object to the axis.
Adds a colorbar object to the axis .
"""
    Adds a colorbar object to the axis.
    
    :param string cbar_format: cbar label formatting, scientific mode '%.1e'
    """
figax
image
cbar_outline
cbar_ori
cbar_fontsize
cbar_pad
ticktitle
ticks
ticklabels
cbar_format
cbar label formatting, scientific mode '%.1e'
cbar label formatting scientific mode ' % . 1e '