Skip to content

Error in alpha: unused argument after loading other library kernlab #8

@danlooo

Description

@danlooo

Hello,

after loading another library like kernlab, I stumbled the following error message after trying to draw with geom_lv:

> library(ggplot2)
> library(lvplot)
> ggplot(mpg, aes(class, hwy)) + geom_lv()
Warning message:
In grSoftVersion() :
  unable to load shared object '/usr/local/lib/R/modules//R_X11.so':
  libXt.so.6: cannot open shared object file: No such file or directory
> ggplot(mpg, aes(class, hwy)) + geom_lv()
> library(kernlab)

Attaching package: ‘kernlab’

The following object is masked from ‘package:ggplot2’:

    alpha

> ggplot(mpg, aes(class, hwy)) + geom_lv()
Error in alpha(data$fill, data$alpha) : unused argument (data$alpha)

However, it worked before loading the library kernlab. Are there any namespace issues?

Code to reproduce (tested on the docker container with image rocker/tidyverse:4.1)

devtools::install_github("hadley/lvplot@8ce61c7", upgrade = "never")
install.packages("kernlab")

library(ggplot2)
library(lvplot)

ggplot(mpg, aes(class, hwy)) + geom_lv()

library(kernlab)
ggplot(mpg, aes(class, hwy)) + geom_lv()

Current workaround:

Do detach("package:kernlab", unload=TRUE) before and library(kernlab) after calling geom_lv

Thanks for any suggestions!

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