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

polygon glyph #173

Open
z267xu opened this issue Jan 19, 2022 · 0 comments
Open

polygon glyph #173

z267xu opened this issue Jan 19, 2022 · 0 comments

Comments

@z267xu
Copy link
Contributor

z267xu commented Jan 19, 2022

Describe the bug
In a loon plot with a single point, after adding the polygon glyph, the coordinates of the polygons are missing. Problems should be in the tcl file.

For example,

x_star <-
  c(-0.000864304235090734, 0.292999135695765, 0.949870354364736,
    0.474503025064823, 0.586862575626621, -0.000864304235090734,
    -0.586430423509075, -0.474070872947277, -0.949438202247191,
    -0.29256698357822)
y_star <-
  c(-1, -0.403630077787381, -0.308556611927398, 0.153846153846154,
    0.808556611927398, 0.499567847882455, 0.808556611927398,
    0.153846153846154, -0.308556611927398, -0.403630077787381)

p <- l_plot(1,1)
gl <- l_glyph_add_polygon(p, 
                          x = list(x_star),
                          y = list(y_star))

p['glyph'] <- gl

> gl['x']
[[1]]
[1] NA

> gl['y']
[[1]]
[1] NA
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant