Skip to contents

This stat performs identity transformation (passes data through unchanged) while properly handling discrete scales for 3D coordinate systems. It can optionally generate reference lines and points projecting to cube faces.

Usage

stat_point_3d(
  mapping = NULL,
  data = NULL,
  geom = "point_3d",
  position = "identity",
  na.rm = FALSE,
  show.legend = NA,
  inherit.aes = TRUE,
  raw_points = TRUE,
  ref_lines = FALSE,
  ref_points = "circles",
  ref_faces = "zmin",
  ref_circle_radius = 0.02,
  ref_circle_vertices = 16,
  ...
)

Arguments

mapping

Set of aesthetic mappings created by aes(). This stat requires x, y, and z aesthetics.

data

The data to be displayed in this layer.

geom

The geometric object to use display the data.

position

Position adjustment, defaults to "identity".

na.rm

If FALSE, missing values are removed with a warning.

show.legend

Logical indicating whether this layer should be included in legends.

inherit.aes

If FALSE, overrides the default aesthetics.

raw_points

Logical indicating whether to show the primary 3D points.

ref_lines

Logical indicating whether to show reference lines to faces.

ref_points

Type of reference points to create. Options:

  • FALSE: No reference points

  • "circles": Circular reference points that project properly (default)

  • "points": Single-point references (legacy behavior)

ref_faces

Character vector specifying which faces to project to. Uses same vocabulary as coord_3d panels argument. Default "zmin" uses bottom face.

ref_circle_radius

Radius for circular reference points in standardized coordinate units.

ref_circle_vertices

Number of vertices for circular reference points (higher = smoother).

...

Other arguments passed on to layer().

Computed variables

  • x_raw, y_raw, z_raw: Original values before discrete-to-numeric conversion

  • element_type: Type of element ("raw_point", "ref_point", "ref_line", "ref_circle")

  • segment_id: ID linking the two endpoints of reference lines

  • ref_face: Which face reference elements project to

  • ref_circle_radius: Radius for circular reference points

  • ref_circle_vertices: Number of vertices for circular reference points

See also

geom_point_3d() which uses this stat by default.