Skip to content

Unhelpful error when facet = FALSE, facet.args = list(free = TRUE) #553

@katrinabrock

Description

@katrinabrock

MRE

library(tinyplot)

aq = transform(
  airquality,
  Month = factor(month.abb[Month], levels = month.abb[5:9]),
  hot = ifelse(Temp >= 75, "hot", "cold"),
  windy = ifelse(Wind >= 15, "windy", "calm")
)

tinyplot(
  Temp ~ Day,
  data = aq,
  facet.args = list(free = TRUE),
)

Expected behavior

Silently ignore facet args. (This is what happens when other facet args are specified in this situation.)

Actual behavior

Error in split.default(c(x, xmin, xmax), facet) : 
  group length is 0 but data length > 0

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions