Skip to content

Bug: geom_raster() fails on devel #5411

@teunbrand

Description

@teunbrand

When x and y are discrete, one of the pixels seem to take over whole raster.

Reprex:

devtools::load_all("~/packages/ggplot2")
#> ℹ Loading ggplot2

df <- data.frame(
  x = rep(c("A", "B"), 2),
  y = rep(c("C", "D"), each = 2),
  z = letters[1:4]
)

ggplot(df, aes(x, y, fill = z)) +
  geom_raster()

Created on 2023-09-08 with reprex v2.0.2

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions