Visualizer

class fcapy.visualizer.Visualizer(lattice=None, node_color='blue', cmap='Blues', node_alpha=1, node_linewidth=1, node_edgecolor='blue', cmap_min=None, cmap_max=None)

A class for visualizing the ConceptLattice

draw_networkx(...):

Draw a ConceptLattice line diagram with networkx package

get_plotly_figure(...):

Return a Plotly figure with the ConceptLattice line diagram

draw_networkx(draw_node_indices=False, edge_radius=None, max_new_extent_count=3, max_new_intent_count=3)

Draw line diagram of the ConceptLattice with networkx package

Parameters
  • draw_node_indices (bool) – A flag whether to draw indexes of nodes inside the nodes

  • edge_radius (float) – A value of how much curve the edges on line diagram should be

  • max_new_extent_count (int) – A number of new objects in concept extent to draw

  • max_new_intent_count (int) – A number of new attributes in concept intent to draw

get_nodes_position(lattice=None)

Return a dict of nodes positions in a line diagram

get_plotly_figure(**kwargs)

Get a line diagram of ConceptLattice constructed by plotly package

Parameters

kwargs

colorbar_title: str

A title of colorbar axis

max_new_extent_count: int

A number of new objects in concept extent to draw

max_new_intent_count: int

A number of new objects in concept extent to draw

xlim: tuple of `float

A tuple of xaxis ranges (x_left, x_right) (default value is (-1, 1))

figsize: tuple of float

A tuple of size of a figure (width, height) (default value is (1000, 500))

Returns

fig – A line diagram of ConceptLattice in the form of Plotly Figure

Return type

plotly.graph_objects.Figure