Figure
A 2-D figure: marks in data coordinates, two axes, a legend, an optional color scale. Immutable: + adds a mark or a Tweak (labels, scales, size, palette, style), ++ more marks, copy changes the rest. svg renders it (Svg); view() shows it live; save("f.svg") writes it.
The parts follow the grammar of graphics: the marks are the data drawn, x and y the position scales, palette with degrees and colorScale the color scales, legend and the color bar their guides, style the look and elements its finer parts (each text, the lines, the plot area). legendPlace is where the plot puts its legend unless the style says otherwise. equalAspect keeps a unit of x as long as a unit of y when both axes are on one scale, and aspect is any other ratio of the length of a y unit to an x unit (Scale.aspect). caption is a line of text under the plot, tag the letter of a panel of a board, and description what a screen reader says of the plot (the `` of the SVG).
Attributes
- Experimental
- true
- Source
- Figure.scala
- Graph
-
- Supertypes
-
trait Serializabletrait Producttrait Equalstrait Plotclass Objecttrait Matchableclass AnyShow all
Members list
Value members
Concrete methods
Attributes
- Source
- Figure.scala
This figure with the change tweak makes: fig + Labels(title = "A circle") + Scale.xy(Transform.Log10).
This figure with the change tweak makes: fig + Labels(title = "A circle") + Scale.xy(Transform.Log10).
Attributes
- Source
- Figure.scala
Attributes
- Source
- Figure.scala
The plot as a fragment to embed in a page (an ``, or a `
The plot as a fragment to embed in a page (an ``, or a `
` with its own script for 3-D).
Attributes
- Source
- Figure.scala
A complete HTML page, following the reader's light or dark setting under Theme.Auto.
A complete HTML page, following the reader's light or dark setting under Theme.Auto.
Attributes
- Source
- Figure.scala
This figure's marks drawn over under's (axes, title, legend heading and look from this one, legends merged; the color scale of whichever has one).
This figure's marks drawn over under's (axes, title, legend heading and look from this one, legends merged; the color scale of whichever has one).
Attributes
- Source
- Figure.scala
The visible range of each axis in data units, ((xMin, xMax), (yMin, yMax)), as svg will draw it before any adjustment for an equal aspect ratio.
The visible range of each axis in data units, ((xMin, xMax), (yMin, yMax)), as svg will draw it before any adjustment for an equal aspect ratio.
Attributes
- Source
- Figure.scala
Attributes
- Source
- Figure.scala
A complete SVG document in plain colors (for a 3-D scene: one fixed view), with no background unless the style asks for one (Style.print, or Style.transparent = false), so that it takes the color of the page it goes onto.
A complete SVG document in plain colors (for a 3-D scene: one fixed view), with no background unless the style asks for one (Style.print, or Style.transparent = false), so that it takes the color of the page it goes onto.
Attributes
- Source
- Figure.scala
Returns a string representation of the object.
Returns a string representation of the object.
The default representation is platform dependent.
Attributes
- Returns
-
a string representation of the object.
- Definition Classes
-
Any
- Source
- Figure.scala
The aspect ratio of the plot area: withAspect(1) for equal units, withAspect(free = true) for none. See Scale.aspect.
The aspect ratio of the plot area: withAspect(1) for equal units, withAspect(free = true) for none. See Scale.aspect.
Attributes
- Source
- Figure.scala
The aspect ratio as a number, for MATLAB and Java: withAspect(1) for equal units.
The aspect ratio as a number, for MATLAB and Java: withAspect(1) for equal units.
Attributes
- Source
- Figure.scala
The axis lines. See Lines.axis.
A line of text under the plot.
The title of the color bar.
The color scale of a heatmap or a cocycle, if the figure has one. See Scale.color.
The color scale of a heatmap or a cocycle, if the figure has one. See Scale.color.
Attributes
- Source
- Figure.scala
The color, legend label and marker of homological degree k. See Scale.degree.
The color, legend label and marker of homological degree k. See Scale.degree.
Attributes
- Source
- Figure.scala
The color of homological degree degree, as a CSS color (#d62728, tomato).
The color of homological degree degree, as a CSS color (#d62728, tomato).
Attributes
- Source
- Figure.scala
The legend label of homological degree degree.
What a screen reader says of the plot (the `` of the SVG).
The diagonal of a persistence diagram and its shaded half plane. See Guide.diagonal.
The diagonal of a persistence diagram and its shaded half plane. See Guide.diagonal.
Attributes
- Source
- Figure.scala
The discs (the balls of a Cech or alpha complex): opacity. See Geom.discs.
The discs (the balls of a Cech or alpha complex): opacity. See Geom.discs.
Attributes
- Source
- Figure.scala
A frame around the plot area (drawn once any setting is given). See Lines.frame.
A frame around the plot area (drawn once any setting is given). See Lines.frame.
Attributes
- Source
- Figure.scala
The gridlines: width, color, dash, opacity. See Lines.grid.
The words: only what is given changes (withLabels(x = "birth") leaves the title). See Labels.
The words: only what is given changes (withLabels(x = "birth") leaves the title). See Labels.
Attributes
- Source
- Figure.scala
The legend at right, bottom, or none.
A box round the legend and its entries in columns: withLegendBox(background = "white", frame = true, columns = 2). See Guide.legend.
A box round the legend and its entries in columns: withLegendBox(background = "white", frame = true, columns = 2). See Guide.legend.
Attributes
- Source
- Figure.scala
A box round the legend, filled with color (a CSS color) and framed: withLegendBox("white").
A box round the legend, filled with color (a CSS color) and framed: withLegendBox("white").
Attributes
- Source
- Figure.scala
The legend's entries in columns columns, one filled before the next.
The heading over the legend's entries.
The polylines (a cycle, a landscape): width. See Geom.lines.
The decimal separator and minus sign of a locale (withLocale("de")). See Numbers.locale.
The decimal separator and minus sign of a locale (withLocale("de")). See Numbers.locale.
Attributes
- Source
- Figure.scala
A factor on the size of markers and the width of lines.
Minor gridlines between the ticks (drawn once any setting is given). See Lines.minorGrid.
Minor gridlines between the ticks (drawn once any setting is given). See Lines.minorGrid.
Attributes
- Source
- Figure.scala
Minor tick marks between the major ones. See Lines.minorTicks.
How the numbers of tick labels and the color bar are written. See Numbers.
How the numbers of tick labels and the color bar are written. See Numbers.
Attributes
- Source
- Figure.scala
With its palette's surface as the background in a saved file too, where it has none unless asked.
With its palette's surface as the background in a saved file too, where it has none unless asked.
Attributes
- Source
- Figure.scala
This palette.
The palette called name: brand, reference, print, grayscale, okabe-ito or clear.
The palette called name: brand, reference, print, grayscale, okabe-ito or clear.
Attributes
- Source
- Figure.scala
The fill of the plot area. See Guide.panel.
The markers of the points: withPoints(size = 3.5, opacity = 0.6, edgeVisible = false). See Geom.points.
The markers of the points: withPoints(size = 3.5, opacity = 0.6, edgeVisible = false). See Geom.points.
Attributes
- Source
- Figure.scala
The filled polygons (a complex's triangles): opacity. See Geom.polygons.
The filled polygons (a complex's triangles): opacity. See Geom.polygons.
Attributes
- Source
- Figure.scala
The line segments (a barcode's bars): width, opacity. See Geom.segments.
The line segments (a barcode's bars): width, opacity. See Geom.segments.
Attributes
- Source
- Figure.scala
One change written as text, element.property=value: withSetting("title.size=18"), withSetting("tick-label.angle=45"), withSetting("grid.dash=dotted"), withSetting("x-axis=top"). See Settings for the elements and their properties.
One change written as text, element.property=value: withSetting("title.size=18"), withSetting("tick-label.angle=45"), withSetting("grid.dash=dotted"), withSetting("x-axis=top"). See Settings for the elements and their properties.
Attributes
- Source
- Figure.scala
The size in pixels; give one to keep the other (withSize(width = 900)).
The size in pixels; give one to keep the other (withSize(width = 900)).
Attributes
- Source
- Figure.scala
The size in pixels.
This style, in place of the figure's.
The style called name: default, slides, print or clear.
The line under the heading.
The letter or number of a panel, in the corner of the figure: "(a)".
The look of one kind of text: withText(TextRole.Title, size = 18, align = Anchor.Middle). See Text.
The look of one kind of text: withText(TextRole.Title, size = 18, align = Anchor.Middle). See Text.
Attributes
- Source
- Figure.scala
A factor on every text size (1.3 for a slide).
Tick marks at the major ticks: withTickMarks(length = 4). See Lines.ticks.
Tick marks at the major ticks: withTickMarks(length = 4). See Lines.ticks.
Attributes
- Source
- Figure.scala
The heading.
Without a background, so that the figure takes the color of the page behind it, in a saved file and on a page.
Without a background, so that the figure takes the color of the page behind it, in a saved file and on a page.
Attributes
- Source
- Figure.scala
The x axis drawn through y = value (see Scale.x), for MATLAB and Java: withXCrossesAt(0).
The x axis drawn through y = value (see Scale.x), for MATLAB and Java: withXCrossesAt(0).
Attributes
- Source
- Figure.scala
The x axis label.
The visible range of the x axis, in data units.
The x axis: its scale, visible range, ticks, number format, gridlines, and its side (Side.Top). See Scale.x.
The x axis: its scale, visible range, ticks, number format, gridlines, and its side (Side.Top). See Scale.x.
Attributes
- Source
- Figure.scala
The x axis on the scale called name: linear, log, sqrt or symlog.
Both axes alike: a log-log diagram is withXYScale(Transform.Log10).
The y axis drawn through x = value (see Scale.y), for MATLAB and Java: withYCrossesAt(0).
The y axis drawn through x = value (see Scale.y), for MATLAB and Java: withYCrossesAt(0).
Attributes
- Source
- Figure.scala
The y axis label.
The visible range of the y axis, in data units.
The y axis; as withXScale.
The y axis on the scale called name: linear, log, sqrt or symlog.
Without gridlines.
Inherited methods
fragment in the theme called theme (auto, light or dark), for callers that have a word, not a Theme (Python: a notebook shows an interactive plot by its fragment).
fragment in the theme called theme (auto, light or dark), for callers that have a word, not a Theme (Python: a notebook shows an interactive plot by its fragment).
Attributes
- Inherited from:
- Plot
- Source
- Plot.scala
An iterator over the names of all the elements of this product.
An iterator over the names of all the elements of this product.
Attributes
- Inherited from:
- Product
- Source
- Product.scala
An iterator over all the elements of this product.
An iterator over all the elements of this product.
Attributes
- Returns
-
in the default implementation, an
Iterator[Any] - Inherited from:
- Product
- Source
- Product.scala
save in the theme called theme (auto, light or dark), for callers that have a word, not a Theme (MATLAB: fig.save('diagram.svg', 'dark')).
save in the theme called theme (auto, light or dark), for callers that have a word, not a Theme (MATLAB: fig.save('diagram.svg', 'dark')).
Attributes
- Inherited from:
- Plot
- Source
- Plot.scala
save in the default theme for the file type, for callers that cannot use a default argument (Java, MATLAB: fig.save('diagram.svg')).
save in the default theme for the file type, for callers that cannot use a default argument (Java, MATLAB: fig.save('diagram.svg')).
Attributes
- Inherited from:
- Plot
- Source
- Plot.scala
Writes the plot to path: an .svg file in plain light colors with no background (another theme on request; see svgFile), or an .html page (interactive for 3-D) that follows the reader's light or dark setting and has its background. Returns the absolute path.
Writes the plot to path: an .svg file in plain light colors with no background (another theme on request; see svgFile), or an .html page (interactive for 3-D) that follows the reader's light or dark setting and has its background. Returns the absolute path.
Attributes
- Inherited from:
- Plot
- Source
- Plot.scala
Shows the plot in the live viewer, a browser tab that adds every plot view()ed (see Viewer). Inside Plot.viewWith the plot goes to the program that hosts the session instead.
Shows the plot in the live viewer, a browser tab that adds every plot view()ed (see Viewer). Inside Plot.viewWith the plot goes to the program that hosts the session instead.
Attributes
- Inherited from:
- Plot
- Source
- Plot.scala