VegaLite.jl icon indicating copy to clipboard operation
VegaLite.jl copied to clipboard

WARN Missing type for channel "x", using "quantitative" instead

Open logankilpatrick opened this issue 4 years ago • 2 comments

Hey all, this is in regards to this thread: https://stackoverflow.com/questions/64849353/julia-vegalite-jl-how-to-disable-the-warninigs/64852944?noredirect=1#comment114697860_64852944

The crux of the issue is that these warnings below only show up in a notebook (and not when running in the Repl). Any suggestions to remove these? (I looked around eh source code for the warning message but it did not show on GitHub search.

Code:

  α  = rand(10,2)
  β  = rand(10,2)
  v1 = @vlplot(:circle,x=α[:,1],y=α[:,2])
  v2 = @vlplot(mark={"type"=:circle,color="red"},x=β[:,1],y=β[:,2])
  @vlplot()+v1+v2

Gives the following warnings:

WARN Missing type for channel "x", using "quantitative" instead.
WARN Missing type for channel "y", using "quantitative" instead.
WARN Missing type for channel "x", using "quantitative" instead.
WARN Missing type for channel "y", using "quantitative" instead.
WARN Missing type for channel "x", using "quantitative" instead.
WARN Missing type for channel "y", using "quantitative" instead.
WARN Missing type for channel "x", using "quantitative" instead.
WARN Missing type for channel "y", using "quantitative" instead.

logankilpatrick avatar Nov 17 '20 15:11 logankilpatrick

@logankilpatrick those warnings come from the underlying vega-lite js package. I'm guessing this has to do with how IJulia imports/displays vega plots vs the version shipped with VegaLite.jl for the REPL.

The IJulia version of vega-lite comes from the extension that ships with Jupyter, whereas there are artifacts that are used when plotting from the repl. How the two are displayed, I believe also differs, but I haven't looked at that code in a fair while.

mcmcgrath13 avatar Nov 17 '20 15:11 mcmcgrath13

I'm pretty positive that the problem is that Jupyter Lab ships a very outdated version of vega and vega-lite, and I think this was something that was fixed in vega and vega-lite in more recent versions. Only hope we have on that is that Jupyter Lab starts to ship a more recent version of vega and vega-lite... I opened an issue for that over there.

davidanthoff avatar Mar 11 '21 01:03 davidanthoff