The following code ought to show two points, at (0., 1 m) and at (0., 2 m).
data.frame(x = 0., y = units::make_units(m) * 1.) |>
ggplot2::ggplot(ggplot2::aes(.data$x, .data$y)) +
units::scale_y_units() +
ggplot2::geom_point() +
ggplot2::geom_point(data = data.frame(x = 0., y = units::make_units(km) * 0.002))
However, it does not show the second point:
Warning message:
Removed 1 row containing missing values or values outside the scale range (`geom_point()`).
Strangely, substituting 2,000 mm for 0.002 km causes the point to be shown:
data.frame(x = 0., y = units::make_units(m) * 1.) |>
ggplot2::ggplot(ggplot2::aes(.data$x, .data$y)) +
units::scale_y_units() +
ggplot2::geom_point() +
ggplot2::geom_point(data = data.frame(x = 0., y = units::make_units(mm) * 2000.))
