reno.diagrams#

Functions for generating stock & flow diagrams.

Diagrams are graphviz dot diagrams, and notably don’t follow the exact format typically used with SFDs. The biggest difference is sources and sinks aren’t explicitly represented.

Classes

DiagramEdge(source, target)

A visual connection between nodes (references) in a stock and flow diagram.

DiagramNode(ref, diagram)

Parent class for any type of node representing a reference in a model.

FlowDiagramNode(ref, diagram)

Node for a flow component.

MetricDiagramNode(ref, diagram)

Node for a metric component.

ModelDiagram(model[, _model_map, _level, ...])

A graph representation of a model, where nodes are the components and the edges represent the connections between them based on their equations.

RenderConfig([show, hide, show_groups, ...])

Settings for what gets rendered in a stock and flow diagram.

StockDiagramNode(ref, diagram)

Node for a stock component.

StockIODiagramEdge(source, target)

Edge between a stock and a inflow or outflow.

StockLimitDiagramEdge(source, target)

Edge between a variable and a stock, where the variable is referenced in a limit/constraint (min/max) on the stock.

ToFlowDiagramEdge(source, target)

Reference edge that connects to a flow.

ToMetricDiagramEdge(source, target)

Reference edge that represents usage in a metric.

ToVarDiagramEdge(source, target)

Reference edge that connects to a variable.

VarDiagramNode(ref, diagram)

Node for a variable component.