We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
We could add some basic visualization routines using Plots.jl (and create a documentation section about it).
For instance, this is what I use right now:
Plotting only the points:
scatter(data_points[1, :], data_points[2, :], legend=false, title="points")
Adding triangulation to the plot:
for element in axes(vertices, 2) v1 = vertices[1, element] v2 = vertices[2, element] v3 = vertices[3, element] x1 = data_points[:, v1] x2 = data_points[:, v2] x3 = data_points[:, v3] plot!(p, [x1[1], x2[1]], [x1[2], x2[2]]) plot!(p, [x2[1], x3[1]], [x2[2], x3[2]]) plot!(p, [x3[1], x1[1]], [x3[2], x1[2]]) end plot!(title = "triangles")
Data points and polygons (here with :centroids):
:centroids
p1 = scatter(data_points[1, :], data_points[2, :], legend=false) for element_vor in axes(voronoi_vertices_interval, 2) vertex_first = voronoi_vertices_interval[1, element_vor] vertex_last = voronoi_vertices_interval[2, element_vor] for i in vertex_first:(vertex_last-1) v1 = voronoi_vertices[i] v2 = voronoi_vertices[i + 1] x1 = voronoi_vertices_coordinates[:, v1] x2 = voronoi_vertices_coordinates[:, v2] plot!(p1, [x1[1], x2[1]], [x1[2], x2[2]]) end v1 = voronoi_vertices[vertex_last] v2 = voronoi_vertices[vertex_first] x1 = voronoi_vertices_coordinates[:, v1] x2 = voronoi_vertices_coordinates[:, v2] plot!(p1, [x1[1], x2[1]], [x1[2], x2[2]], title="mesh type: $mesh_type") end
The variables names are chosen as in the elixirs.
The text was updated successfully, but these errors were encountered:
No branches or pull requests
We could add some basic visualization routines using Plots.jl (and create a documentation section about it).
For instance, this is what I use right now:
Plotting only the points:
Adding triangulation to the plot:
Data points and polygons (here with
:centroids
):The variables names are chosen as in the elixirs.
The text was updated successfully, but these errors were encountered: