vegawidget/virgo

Grouping aesthetic for line marks

Closed this issue · 4 comments

I believe this is called detail in vega-lite https://vega.github.io/vega-lite/docs/line.html#line-detail

Should we implement this as enc(group = ...) or leave it as detail?

Yes, we've implemented as group instead of detail.

virgo/demo/basics.R

Lines 22 to 25 in 63c1ebd

mtcars %>%
mutate(cyl = factor(cyl)) %>%
vega(encoding = enc(x = wt, y = mpg, group = cyl)) %>%
mark_line()

It doesn't seem to be stacking right for me

lex <- gapminder %>% 
  vega(enc(x = year, y = lifeExp, group = country)) %>% 
  mark_line() 
 lex

image

Oops, detail, not details 😅

haha gotcha, thanks!