I'm trying some experiments to figure out how to draw lines and arrows on a graph in JSL. There is not much that has helped me in the Scripting Guide and I didn't see anything previously posted in the community. I have uploaded my JSL script and data table below.
In the data table, I have calculated the coordinates for a unit circle at 5 degree intervals. I plotted these with Graph Builder...

Initially, what I would like to do is script an arrow from the origin to each point. Here is the script I am using. I don't get any errors when I run it but it never draws the arrows. I have tried putting the FOR loop within the Graph Builder block as shown here and also outside the block. I can't seem to get either to work.
Names Default To Here (1);
dt = "Circle Arrow Data";
Graph Builder(
Size( 540, 540 ),
Graph Spacing( 10 ),
Spacing Borders( 1 ),
Variables( X( :x coord ), Y( :y coord ) ),
Elements( Points( X, Y, Legend( 3 ) ) ),
For( i=0, i<360, i+=5,
Arrow( {0,:x coord[i]}, {0, :y coord[i]})
)
);
Ultimately, my goal is to only have the arrows appear when a row or rows are selected but obviously I need to get this working first. This is really about showing wind direction on a graph but I'm taking baby steps in understanding how to draw on graphs.
Thanks in advance for any guidance provided.