cortex.quickflat.make_figure(braindata, recache=False, pixelwise=True, thick=32, sampler='nearest', height=1024, dpi=100, depth=0.5, with_rois=True, with_sulci=False, with_labels=True, with_colorbar=True, with_borders=False, with_dropout=False, with_curvature=False, extra_disp=None, with_connected_vertices=False, overlay_file=None, linewidth=None, linecolor=None, roifill=None, shadow=None, labelsize=None, labelcolor=None, cutout=None, curvature_brightness=None, curvature_contrast=None, curvature_threshold=None, fig=None, extra_hatch=None, colorbar_ticks=None, colorbar_location='center', roi_list=None, nanmean=False, **kwargs)[source]

Show a Volume or Vertex on a flatmap with matplotlib.

Note that **kwargs are ONLY present now for backward compatibility / warnings. No kwargs should be used.

braindataDataview (e.g. instance of cortex.Volume, cortex.Vertex,…)

the data you would like to plot on a flatmap


Whether or not to recache intermediate files. Takes longer to plot this way, potentially resolves some errors. Useful if you’ve made changes to the alignment


Use pixel-wise mapping


Number of layers through the cortical sheet to sample. Only applies for pixelwise = True


Name of sampling function used to sample underlying volume data. Options include ‘trilinear’, ‘nearest’, ‘lanczos’; see functions in for all options


Height of the image to render. Automatically scales the width for the aspect of the subject’s flatmap


Value between 0 and 1 for how deep to sample the surface for the flatmap (0 = gray/white matter boundary, 1 = pial surface)

with_rois, with_labels, with_colorbar, with_borders, with_dropout, with_curvature, etcbool, optional

Display the rois, labels, colorbar, annotated flatmap borders, etc


Name of flatmap cutout with which to clip the full flatmap. Should be the name of a sub-layer of the ‘cutouts’ layer in <filestore>/<subject>/overlays.svg

Other Parameters

DPI of the generated image. Only applies to the scaling of matplotlib elements, specifically the colormap

linewidthint, optional

Width of ROI lines. Defaults to roi options in your local options.cfg

linecolortuple of float, optional

(R, G, B, A) specification of line color

roifilltuple of float, optional

(R, G, B, A) sepcification for the fill of each ROI region

shadowint, optional

Standard deviation of the gaussian shadow. Set to 0 if you want no shadow

labelsizestr, optional

Font size for the label, e.g. “16pt”

labelcolortuple of float, optional

(R, G, B, A) specification for the label color

curvature_brightnessfloat, optional

Mean* brightness of background. 0 = black, 1 = white, intermediate values are corresponding grayscale values. If None, Defaults to config file value. (*this does not precisely specify the mean; the actual mean luminance of the curvature depends on the value for curvature_contrast. It’s easiest to think about it as the mean brightness, though.)

curvature_contrastfloat, optional

Contrast of curvature. 1 = maximal contrast (black/white), 0 = no contrast (solid color for curvature equal to curvature_brightness).

cvmaxfloat, optional [DEPRECATED! use curvature_brightness and curvature_contrast instead]

Maximum value for background curvature colormap. Defaults to config file value.

cvthrbool, optional [DEPRECATED! use curvature_threshold instead]

Apply threshold to background curvature

extra_disptuple, optional

Optional extra display layer from external .svg file. Tuple specifies (filename, layer) filename should be a full path. External svg file should be structured exactly as overlays.svg for the subject. (Best to just copy overlays.svg somewhere else and add layers to it.) Default value is None.

extra_hatchtuple, optional

Optional extra crosshatch-textured layer, given as (DataView, [r, g, b]) tuple.

colorbar_locationstr or tuple, optional

Location of the colorbar. Default locations are one of ‘left’, ‘center’, ‘right’ (default ‘center’). Alternatively, a tuple with four floats between 0 and 1 can be passed indicating (left, bottom, width, height).

colorbar_ticksarray-like, optional

For 1D colormaps indicates the ticks of the colorbar. If None, it defaults to equally spaced values between vmin and vmax. This parameter is not used for 2D colormaps, and it defaults to the vmin, vmax specified in the Volume2D object.

figfigure or ax

figure into which to plot flatmap

nanmeanbool, optional (default = False)

If True, NaNs in the data will be ignored when averaging across layers.