Skip to content

RC: CRAN 0.12.0#413

Merged
IndrajeetPatil merged 13 commits intomainfrom
rc-cran-12
Sep 14, 2025
Merged

RC: CRAN 0.12.0#413
IndrajeetPatil merged 13 commits intomainfrom
rc-cran-12

Conversation

@IndrajeetPatil
Copy link
Copy Markdown
Member

  • Update minimum ggplot2 dependency to 4.0.0.

  • Refactor usage of geom_errorbarh to geom_errorbar with orientation='y' for compatibility with ggplot2 4.0.0.

closes #409

Bump package version to 0.12.0 and update minimum ggplot2 dependency to 4.0.0. Refactor usage of geom_errorbarh to geom_errorbar with orientation='y' for compatibility with ggplot2 4.0.0.
@gemini-code-assist
Copy link
Copy Markdown

Note

The number of changes in this pull request is too large for Gemini Code Assist to generate a summary.

@bwiernik
Copy link
Copy Markdown
Contributor

bwiernik commented Sep 11, 2025

A cool 25000 lines of code changed 😎

@strengejacke
Copy link
Copy Markdown
Member

I changed the axis spacing, to fix the issue with narrow axis texts. What do you think? I could update the snapshot tests

@strengejacke
Copy link
Copy Markdown
Member

hm... for some plots, the spacing between axis line and text increased, for others, it decreases when using theme_modern() with ggplot2 4. Not sure what to do, should we leave the code unchanged and accept closer distance when using that theme?

@IndrajeetPatil
Copy link
Copy Markdown
Member Author

Yeah, I would leave it unchanged for now. Let's see if the users give any feedback about this. If they do, we can reassess.

There is one example failing involving geom_from_list? Could you please have a look?

@strengejacke
Copy link
Copy Markdown
Member

Yes, will look into that failing test.
What about adding a new argument to set own values for the spacing?

@strengejacke
Copy link
Copy Markdown
Member

This example fails, not sure why:

# code from example:
ggplot() + geom_from_list(list(geom = "density_2d_raster", data = iris, aes = list(x = "Sepal.Width", y = "Petal.Length")))

# equivalent ggplot code
ggplot() +
  geom_raster(
    data = iris,
    stat = "Density2d",
    aes(x = Sepal.Width, y = Petal.Length, fill = after_stat(density)),
    position = "identity"
  )

@IndrajeetPatil
Copy link
Copy Markdown
Member Author

A cool 25000 lines of code changed 😎

Source code changes are just 5-10 lines.

Most of the other changes are just SVG changes in snapshots. Unfortunately, this is going to be the case every time there is a major ggplot2 release.

@Breeze-Hu
Copy link
Copy Markdown

Breeze-Hu commented Sep 12, 2025

This example fails, not sure why:

# code from example:
ggplot() + geom_from_list(list(geom = "density_2d_raster", data = iris, aes = list(x = "Sepal.Width", y = "Petal.Length")))

# equivalent ggplot code
ggplot() +
  geom_raster(
    data = iris,
    stat = "Density2d",
    aes(x = Sepal.Width, y = Petal.Length, fill = after_stat(density)),
    position = "identity"
  )

Perhaps contour = FALSE influenced the results?

library(ggplot2)
ggplot()+
  geom_raster(
    data = iris,
    aes(x = Sepal.Width, y = Petal.Length,fill = after_stat(density)),
    stat= "Density2d",
    position = "identity",
    contour = FALSE
  )

Created on 2025-09-12 with reprex v2.1.1

@IndrajeetPatil IndrajeetPatil merged commit 82dfe82 into main Sep 14, 2025
22 of 25 checks passed
@IndrajeetPatil IndrajeetPatil deleted the rc-cran-12 branch September 14, 2025 06:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

New CRAN release?

4 participants