ggside-ggproto-facets: Extending base ggproto classes for ggside

ggside-ggproto-facetsR Documentation

Extending base ggproto classes for ggside

Description

S3 class that converts old Facet into one that is compatible with ggside. Can also update ggside on the object. Typically, the new ggproto will inherit from the object being replaced.

check_scales_collapse is a helper function that is meant to be called after the inherited Facet's compute_layout method

sidePanelLayout is a helper function that is meant to be called after the inherited Facet's compute_layout method and after check_scales_collapse

prep_map_data is a utility function to help modify the data and layout variables of the Facet's $map_data method. This will be sure to include the column PANEL_TYPE that will assist where data should map to. Please be sure to join against this column as well.

Usage

as_ggsideFacet(facet, ggside)

check_scales_collapse(data, params)

sidePanelLayout(layout, ggside)

prep_map_data(layout, data)

Arguments

facet

Facet ggproto Object to replace

ggside

ggside object to update

data

data passed through ggproto object

params

parameters passed through ggproto object

layout

layout computed by inherited ggproto Facet compute_layout method

Value

ggproto object that can be added to a ggplot object

Extended Facets

The following is a list ggplot2 facets that are available to use by ggside base.

  • FacetNull -> FacetSideNull

  • FacetGrid -> FacetSideGrid

  • FacetWrap -> FacetSideWrap


ggside documentation built on Dec. 5, 2022, 1:07 a.m.