density_target_measure: The density measure a plot calls for

View source: R/plots.R

density_target_measureR Documentation

The density measure a plot calls for

Description

A density is expressed with respect to two independent choices: the size variable, which follows size_axis, and whether it is per size or per logarithmic size, which follows per_log_size. Plotting against a length axis therefore turns a density with respect to weight into one with respect to length, and a density with respect to logarithmic weight into one with respect to logarithmic length.

Usage

density_target_measure(density_wrt, size_axis, per_log_size = NULL)

Arguments

density_wrt

The measure the values are a density with respect to, see density_measures.

size_axis

Either "w" (weight) or "l" (length).

per_log_size

Whether to express the values per logarithmic size. NULL (the default) keeps whichever the values already are.

Value

The density measure to express the values in, or NA_character_ if the values are not a density.


mizer documentation built on Aug. 24, 2026, 9:08 a.m.