Raxol.UI.Charts.ScatterChart (Raxol v2.6.0)

View Source

Braille-resolution scatter plot for 2D {x, y} data.

Each data point becomes a single braille dot. Multiple series are rendered as separate layers with independent colors. Points that fall outside the display range are silently clipped.

Summary

Functions

Renders a scatter chart into cell tuples.

Types

cell()

series()

@type series() :: %{
  name: String.t(),
  data: [{number(), number()}] | struct(),
  color: atom()
}

Functions

render(arg, series, opts \\ [])

@spec render(
  {non_neg_integer(), non_neg_integer(), pos_integer(), pos_integer()},
  [series()],
  keyword()
) :: [cell()]

Renders a scatter chart into cell tuples.

Options

  • show_axes -- render Y-axis labels and line (default: false)
  • show_legend -- render series legend below chart (default: false)
  • x_range -- {min, max} or :auto (default: :auto)
  • y_range -- {min, max} or :auto (default: :auto)