We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hi there,
I've been trying to add flags to a bar plot using geom_flag. I've been using the following code:
countrytotal$COWcode <- countrycode(countrytotal$Fleet, "country.name", "cown") countrytotal$countryname <- countrycode(countrytotal$COWcode, "cown", "country.name") countrytotal$iso2 <- countrycode(countrytotal$countryname, "country.name", "iso2c") countrytotal$iso2_lower <- tolower(countrytotal$iso2)
plot1 <- ggplot(data=countrytotal, aes(x=Fleet, y=totalcatch)) + geom_bar(stat="identity") + coord_flip() + expand_limits(y = -4) plot1 + geom_flag(aes(y =-4, image = iso2_lower), data=countrytotal)
I continue to get the error message of Error in class(grobs) <- "gList" : attempt to set an attribute on NULL.
Any thoughts on what may be going on? Thank you.
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Hi there,
I've been trying to add flags to a bar plot using geom_flag. I've been using the following code:
countrytotal$COWcode <- countrycode(countrytotal$Fleet, "country.name", "cown")
countrytotal$countryname <- countrycode(countrytotal$COWcode, "cown", "country.name")
countrytotal$iso2 <- countrycode(countrytotal$countryname, "country.name", "iso2c")
countrytotal$iso2_lower <- tolower(countrytotal$iso2)
plot1 <- ggplot(data=countrytotal, aes(x=Fleet, y=totalcatch)) +
geom_bar(stat="identity") +
coord_flip() + expand_limits(y = -4)
plot1 + geom_flag(aes(y =-4, image = iso2_lower), data=countrytotal)
I continue to get the error message of Error in class(grobs) <- "gList" : attempt to set an attribute on NULL.
Any thoughts on what may be going on? Thank you.
The text was updated successfully, but these errors were encountered: