Skip to content
New issue

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

twinx() throws error in custom theme #63

Open
besselfunct opened this issue Mar 25, 2021 · 0 comments
Open

twinx() throws error in custom theme #63

besselfunct opened this issue Mar 25, 2021 · 0 comments

Comments

@besselfunct
Copy link

Hi,

I'm trying to create a custom theme that has the usual settings that I would use in OriginLab for plotting. I've made a modification to wong.jl, and saved it as my own theme:

_themes[:custom] = PlotTheme(
    palette = expand_palette(colorant"white", wong_palette; lchoices [57], cchoices = [100]),
    colorgradient = cgrad(:viridis).colors,
    legend = :false,
    grid = :false,
    twinx(),
    xmirror = :true,
)

However, when I try using Plots with this custom theme, it fails to compile throwing an error about twinx not defined

Is there another syntax for generating a "full" plot (with mirrored x and y axes with tick labels) that could be passed as an argument in a custom theme? After looking over the source code, it looks like twinx() is a function that should be callable, but is maybe getting compiled after PlotThemes.jl?

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

No branches or pull requests

1 participant