custom_datetimeScale: Add date scale with custom styling

Description Usage Arguments Details

View source: R/custom_datetimeScale.R

Description

Add a date scale and custom formatting for creating consistent timeseries plots.

Usage

1
2
3
4
5
custom_datetimeScale(startdate = NULL, enddate = NULL,
  timezone = NULL, expand = c(0, 0.05), break_width = NULL,
  minor_break_width = NULL, date_labels = "%b %d",
  tick_location = c("midnight", "midday")[1],
  includeFullEnddate = TRUE, today_label = TRUE, ...)

Arguments

startdate

Desired start date (integer or character in ymd format or POSIXct).

enddate

Desired end date (integer or character in ymd format or POSIXct).

timezone

Timezone for label formatting.

expand

Vector of range expansion constants used to add some padding around the data, to ensure that they are placed some distance away from the axes.

break_width

Space between breaks. If NULL, suitable breaks are calculated based on the data. See 'Details'.

minor_break_width

Space between minor breaks. If NULL, suitable breaks are calculated based on the data. See 'Details'.

date_labels

date format string for formatting date labels.

tick_location

Location of ticks ("midnight" or "midday")

includeFullEnddate

if TRUE, the x-axis limit is pushed up to include the full final day.

today_label

if FALSE, no label will be generated for today.

...

Additional arguments passed onto scale_x_datetime.

Details

break_width and minor_break_width can be specified in several ways.


MazamaScience/PWFSLSmokePlots documentation built on Oct. 11, 2019, 11:03 p.m.