NetworkArtist
- class compas_rhino.artists.NetworkArtist(*args, **kwargs)[source]
Bases:
compas_rhino.artists.artist.RhinoArtist,compas.artists.networkartist.NetworkArtistArtist for drawing network data structures.
- Parameters
network (
compas.datastructures.Network) – A COMPAS network.layer (str, optional) – The parent layer of the network.
nodes (list of int, optional) – A list of node identifiers. Default is
None, in which case all nodes are drawn.edges (list, optional) – A list of edge keys (as uv pairs) identifying which edges to draw. The default is
None, in which case all edges are drawn.nodecolor (rgb-tuple or dict of rgb-tuples, optional) – The color specification for the nodes.
edgecolor (rgb-tuple or dict of rgb-tuples, optional) – The color specification for the edges.
show_nodes (bool, optional)
show_edges (bool, optional)
Methods
build(item, **kwargs)Build an artist corresponding to the item type.
build_as(item, artist_type, **kwargs)clear()draw([nodes, edges, nodecolor, edgecolor])Draw the network using the chosen visualisation settings.
draw_collection(collection)draw_edgelabels([text, color])Draw labels for a selection of edges.
draw_edges([edges, color])Draw a selection of edges.
draw_nodelabels([text, color])Draw labels for a selection nodes.
draw_nodes([nodes, color])Draw a selection of nodes.
get_artist_cls(data, **kwargs)redraw()register(item_type, artist_type)