Vege-Lite encode :point shape and angle

I want to draw a scatter plot but use different point shape and angles to show different orientations and directions.

the stroke shape and arrow shape seems what I want, but I am have trouble to make it work

function foo(pos;ori=0,dir=90)
    data1 = DataFrame(x=pos[:,1],y=pos[:,2],shape=1,angle=ori)
    data2 = DataFrame(x=pos[:,1],y=pos[:,2],shape=2,angle=dir)
    data = [data1;data2]
    data |> @vlplot(
    width=400,height=400 )

up = [1:10 3:12]


the Vega-Lite says angle is not a valid encoding channel but I saw this.

any suggestions would be appreciated.

This is the same question as here, right? No need to post twice :slight_smile:

EDIT: Sorry I originally used the wrong link here. I think this was the same question that was already asked on github?

1 Like

Strange, your link to the “other” post points exactly to this post here, and I can’t find the duplicate one.
I hesitate to answer the OP because it may be already answered in the “other” duplicate.

“angle” is not supported by VegaLite, see here:

You may try to use Vega syntax (JSON) as in your linked example. On how to use this in Julia can be read here:

You may also consider to use VegaLite#master where Vega support has been slightly improved:

1 Like

VegaLite.jl now supports the angle encoding channel, see this example.