Plot attributes

Below is a list of some common plot attributes for Makie.

To view a plot's attributes and their values, you can call plot.attributes to view the raw output, or plot.attributes.attributes to get a Dict of the attribute keys and their values.

p = scatter(rand(10), rand(10))[end]; # use `[end]` to access the plot
p.attributes
p.attributes.attributes
Dict{Symbol,Observable} with 28 entries:
  :transparency   => Observable{Any} with 0 listeners. Value:…
  :strokecolor    => Observable{Any} with 0 listeners. Value:…
  :specular       => Observable{Any} with 0 listeners. Value:…
  :colormap       => Observable{Any} with 0 listeners. Value:…
  :visible        => Observable{Any} with 0 listeners. Value:…
  :glowwidth      => Observable{Any} with 0 listeners. Value:…
  :marker_offset  => Observable{Any} with 0 listeners. Value:…
  :markersize     => Observable{Any} with 1 listeners. Value:…
  :rotations      => Observable{Any} with 0 listeners. Value:…
  :ssao           => Observable{Any} with 0 listeners. Value:…
  :ambient        => Observable{Any} with 0 listeners. Value:…
  :lightposition  => Observable{Any} with 0 listeners. Value:…
  :nan_color      => Observable{Any} with 0 listeners. Value:…
  :distancefield  => Observable{Any} with 0 listeners. Value:…
  :shininess      => Observable{Any} with 0 listeners. Value:…
  :strokewidth    => Observable{Any} with 0 listeners. Value:…
  :overdraw       => Observable{Any} with 0 listeners. Value:…
  :transformation => Observable{Any} with 0 listeners. Value:…
  :model          => Observable{Any} with 0 listeners. Value:…
  ⋮               => ⋮

List of attributes

SymbolDescription
absorptionFloat32. Sets the absorption value for volume plots.
algorithmAlgorithm to be used for volume plots. Can be one of :iso, :absorption, :mip, :absorptionrgba, or :indexedabsorption.
align(:pos, :pos). Specify the text alignment, where :pos can be :left, :center, or :right.
alphaFloat in [0,1]. The alpha value (transparency).
colorSymbol or Colorant. The color of the main plot element (markers, lines, etc.). Can be a color symbol/string like :red, or a Colorant. Can also be an array or matrix of 'z-values' that are converted into colors by the colormap automatically.
colormapThe color map of the main plot. Call available_gradients() to see what gradients are available. Can also be used with any Vector{<: Colorant}, or e.g. [:red, :black], or ColorSchemes.jl colormaps (by colormap = ColorSchemes.<colorscheme name>.colors).
colorrangeA tuple (min, max) where min and max specify the data range to be used for indexing the colormap. E.g. color = [-2, 4] with colorrange = (-2, 4) will map to the lowest and highest color value of the colormap.
fillrangeBool. Toggles range filling in contour plots.
fontString. Specifies the font, and can choose any font available on the system.
glowcolorColor Type. Color of the marker glow (outside the border) in scatter plots.
glowwidthNumber. Width of the marker glow in scatter plots.
imageThe image to be plotted on the plot.
interpolateBool. For heatmap and images. Toggles color interpolation between nearby pixels.
isorangeFloat32. Sets the isorange for volume plots.
isovalueFloat32. Sets the isovalue for volume plots.
levelsInteger. Number of levels for a contour-type plot.
linestyleSymbol. Style of the line (for line and linesegments plots). Available styles are :dash, :dot, :dashdot, and :dashdotdot. You can also supply an array describing the length of each gap/fill.
linewidthNumber. Width of the line in line and linesegments plots.
markerSymbol, Shape, or AbstractVector.
marker_offsetArray of GeometryTypes.Point's. Specifies the offset coordinates for the markers. See the Marker offset example.
markersizeNumber or AbstractVector. Specifies size (radius pixels) of the markers.
positionNTuple{2,Float}, (x, y). Specify the coordinates to position text at.
rotationFloat32. Specifies the rotation in radians.
rotationsAbstractVector{Float32}. Similar to :rotation, except it specifies the rotations for each element in the plot.
shadingBool. Specifies if shading should be on or not (for meshes).
strokecolorColor Type. Color of the marker stroke (border).
strokewidthNumber. Width of the marker stroke (in pixels).
textsizeInteger. Font pointsize for text.
transformation(:plane, location). Transforms the :plane to the specified location. Possible :plane's are :xy, :yz, and :xz.
visibleBool. Toggle visibility of plot.