Lets-Plot for Kotlin 4.9.3 Help

Miscellaneous

Panning and Zooming

Use the ggtb function to enable Pan and Zoom interactivity on a chart.

This function adds a toolbar containing three tool-buttons: pan, rubber-band zoom, and center-point zoom.

See: interact_pan_zoom.ipynb

Zoom and Pan interactivity

Extended Text Markup

In tooltips/labels/texts and wherever else there is text, you can use:

  • Interactive links, e.g. <a href="https://github.com">GitHub</a>.

    See: lp_verse.ipynb

    The observable LP-verse
  • LaTeX formulas with

    • superscript, e.g. \( a^b \);

    • subscript, e.g. \( x_i \);

    • Greek letters, e.g. \( \Omega \), and

    • some special symbols, e.g. \( a \cdot b \neq c \).

    See: latex_support.ipynb

    LaTeX Support

Manual Legend

In Lets-Plot, as in ggplot2, legends are automatically generated based on the aesthetic mappings in the plot. Sometimes, however, this automatic generation doesn't provide the precise control needed for complex visualizations. Parameter manualKey and aesthetic parameters of the guideLegend() function addresses this limitation.

See: manual_legend.ipynb

Custom Legend with manualKey Option

Multiple Color Scales

Use colorBy/fillBy parameters and paint_a/paint_b/paint_c aesthetics if you need to display two different layers with the same color aesthetic but different color scales.

See: multiple_color_scales.ipynb

Multiple color scales

Scale Functions

To specify a scale for any group of aesthetics, use the special scale functions: scaleManual(), scaleContinuous(), scaleGradient(), etc.

See: scale_functions.ipynb

Scale functions with parameter aesthetic

Quantiles

Density-like plots let you show the quantiles by mapping them to a particular colour palette.

See: quantile_parameters.ipynb

Showing quantiles on density plots

Stackable Position Adjustments

To configure positioning where groups are stacked on top of each other, use the positionStack() and positionFill() functions.

See: position_stack.ipynb

Stackable position adjustments
Last modified: 01 November 2024