Skip to content

Line

Mojo struct 🡭

Line

@memory_only
struct Line

Mark.LINE as a type. Built by Plot.mark_line().

Aliases

  • id = Mark.LINE
  • supports_tooltips = False
  • supports_data_labels = False
  • supports_horizontal = False
  • supports_annotations_y = True
  • supports_annotations_x = True
  • supports_annotations_xy = True
  • supports_log_x = True
  • supports_log_y = True
  • supports_color_size = False
  • straight_edged = True
  • continuous_path = True
  • layerable = True
  • color_is_value = False
  • categorical_bars = False
  • bar_combo_overlay = True
  • continuous_error_bars = True

Fields

  • continuous (_ContinuousData)
  • channels (_ChannelData)
  • y_err (_ErrorBarData)
  • categorical (_CategoricalData)

Implemented traits

AnyType, Copyable, Deinitable, MarkType, Movable

Methods

__init__

fn def __init__(out self)

Args:

  • self (Self)

Returns:

Self

render

fn def render[T: DrawTarget](self, mut target: T, style: _MarkStyle, annotations: _AnnotationData, settings: _ChartSettings, ox0: Int, oy0: Int, ox1: Int, oy1: Int, has_shared_y_domain: Bool, shared_y_min: Float64, shared_y_max: Float64, shared_y_is_log: Bool, *, mut cache: FontCache, vector_target: Bool) -> _RenderResult

Parameters:

  • T (DrawTarget)

Args:

  • self (Self)
  • target (T)
  • style (_MarkStyle)
  • annotations (_AnnotationData)
  • settings (_ChartSettings)
  • ox0 (Int)
  • oy0 (Int)
  • ox1 (Int)
  • oy1 (Int)
  • has_shared_y_domain (Bool)
  • shared_y_min (Float64)
  • shared_y_max (Float64)
  • shared_y_is_log (Bool)
  • cache (FontCache)
  • vector_target (Bool)

Returns:

_RenderResult

Raises:

encode

fn def encode(mut self, mut settings: _ChartSettings, x: List[Float64], y: List[Float64], color: List[Float64] = List(), color_categories: List[String] = List(), size: List[Float64] = List(), y_err: List[Float64] = List(), y_err_lower: List[Float64] = List(), y_err_upper: List[Float64] = List(), color_map: Dict[String, Color] = Dict(), shape_map: Dict[String, PointShape] = Dict(), labels: List[String] = List(), x_err: List[Float64] = List(), x_err_lower: List[Float64] = List(), x_err_upper: List[Float64] = List())

Args:

  • self (Self)
  • settings (_ChartSettings)
  • x (List[Float64])
  • y (List[Float64])
  • color (List[Float64])
  • color_categories (List[String])
  • size (List[Float64])
  • y_err (List[Float64])
  • y_err_lower (List[Float64])
  • y_err_upper (List[Float64])
  • color_map (Dict[String, Color])
  • shape_map (Dict[String, PointShape])
  • labels (List[String])
  • x_err (List[Float64])
  • x_err_lower (List[Float64])
  • x_err_upper (List[Float64])

Raises:

encode_time

fn def encode_time(mut self, mut settings: _ChartSettings, x: List[Morrow], y: List[Float64])

Args:

  • self (Self)
  • settings (_ChartSettings)
  • x (List[Morrow])
  • y (List[Float64])

Raises:

encode_frame

fn def encode_frame(mut self, mut settings: _ChartSettings, df: DataFrame, x: String, y: String, color: String, size: String, labels: String)

Args:

  • self (Self)
  • settings (_ChartSettings)
  • df (DataFrame)
  • x (String)
  • y (String)
  • color (String)
  • size (String)
  • labels (String)

Raises: