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

How to pass "kwargs" to @vlplot? #344

Open
davibarreira opened this issue Nov 24, 2020 · 1 comment
Open

How to pass "kwargs" to @vlplot? #344

davibarreira opened this issue Nov 24, 2020 · 1 comment

Comments

@davibarreira
Copy link

I'm working on QuickVega.jl, and I'd like to pass kwargs to @vlplot, for example:

function scatterplot(data; x_col=:x, y_col=:y, kwargs...) # assumes Tables.jl format
    data |> @vlplot(:circle, x=x_col, y=y_col; kwargs...)
end

But this does not work. Is there a standard/recommended way of doing?

@davidanthoff
Copy link
Member

It would probably be easiest to use the function, rather than the macro version, of vlplot.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants