Skip to content

Error with coord_polar #42

@mevers

Description

@mevers

Using theme(axis.text.x = element_markdown()) with coord_polar causes an error (but still correctly draws the plot):

Error in grid.Call.graphics(C_setviewport, vp, TRUE) :
non-finite location and/or size for viewport

Minimal & reproducible example:

df <- data.frame(name = sprintf("**%s**", LETTERS[1:4]), value = 1:4)

library(ggtext)
library(ggplot2)

ggplot(df, aes(name, value)) +
    geom_point() +
    coord_polar() +
    theme(axis.text.x = element_markdown())

example

This issue seems to be related to the polar coordinates, as removing coord_polar gets rid of the error

ggplot(df, aes(name, value)) +
    geom_point() +
    theme(axis.text.x = element_markdown())

example

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions