Compute networks (the kind with nodes and edges) on data. Visualize with :py:mod:flotilla.visualize.network
Bases: object
Networks (the kind with nodes and edges), aka a graph
Calculate the edges based on similarity between rows of PCA-reduced data
Construct a Networker object with default node colors (dark teal) and sizes (all nodes at 300)
Calculate the adjacency graph, i.e. connectedness between nodes
Parameters: | data : pandas.DataFrame
use_pc1 : bool, optional
use_pc2 : bool, optional
use_pc3 : bool, optional
use_pc4 : bool, optional
n_pcs : int, optional
|
---|---|
Returns: | adjacency : pandas.DataFrame
|
Given a string, return the function
Used to obtain functions that perform common transforms on distance
Parameters: | fun_name : ‘no_weight’ | ‘sq’ | ‘arctan’ | ‘arctan_sq’, optional
|
---|---|
Returns: | func : function
|
Raises: | ValueError
|
Create a graph based on the adjacency matrix and other inputs
Parameters: | adjacency : pandas.DataFrame
cov_cut : float, optional
node_color_mapper : function, optional
node_size_mapper : function, optional
degree_cut : int
weight_function : ‘no_weight’ | ‘sq’ | ‘arctan’ | ‘arctan_sq’, optional
name : str, optional (default=None)
|
---|---|
Returns: | graph : networkx.Graph
positions : dict
|