Options
All
  • Public
  • Public/Protected
  • All
Menu

Index

Type aliases

EdgeData

EdgeData: object

Type declaration

Variables

CENTER_EDGE_LABEL_MIN_STROKE_WIDTH

CENTER_EDGE_LABEL_MIN_STROKE_WIDTH: 2.5 = 2.5

Minimum stroke width to put edge labels in the middle of edges

DOMAIN_EDGE_WIDTH_SCALE

DOMAIN_EDGE_WIDTH_SCALE: Array<number> = [1, 5E6]

The domain (min and max value) for the edge width.

EDGE_WIDTH_SCALE

EDGE_WIDTH_SCALE: any = d3.scale.pow().exponent(EDGE_WIDTH_SCALE_EXPONENT).domain(DOMAIN_EDGE_WIDTH_SCALE).range([MIN_EDGE_WIDTH, MAX_EDGE_WIDTH]).clamp(true)

EDGE_WIDTH_SCALE_EXPONENT

EDGE_WIDTH_SCALE_EXPONENT: 0.3 = 0.3

The exponent used in the power scale for edge thickness.

MAX_EDGE_WIDTH

MAX_EDGE_WIDTH: 12 = 12

The maximum stroke width of an edge.

MIN_EDGE_WIDTH

MIN_EDGE_WIDTH: 0.75 = 0.75

The minimum stroke width of an edge.

TENSOR_SHAPE_DELIM

TENSOR_SHAPE_DELIM: "×" = "×"

Delimiter between dimensions when showing sizes of tensors.

arrowheadMap

arrowheadMap: any = d3.scale.quantize().domain([MIN_EDGE_WIDTH, MAX_EDGE_WIDTH]).range(['small', 'medium', 'large', 'xlarge'])

interpolate

interpolate: any = d3.svg.line<{x: number, y: number}>().interpolate('basis').x((d) => { return d.x;}).y((d) => { return d.y;})

Functions

adjustPathPointsForMarker

  • adjustPathPointsForMarker(points: Point[], marker: d3.Selection, isStart: boolean): Point[]
  • Shortens the path enought such that the tip of the start/end marker will point to the start/end of the path. The marker can be of arbitrary size.

    Parameters

    • points: Point[]

      Array of path control points.

    • marker: d3.Selection

      D3 selection of the svg element.

    • isStart: boolean

      Is the marker a start-marker. If false, the marker is an end-marker.

    Returns Point[]

    The new array of control points.

appendEdge

  • appendEdge(edgeGroup: any, d: EdgeData, sceneElement: object, edgeClass?: string): void
  • For a given d3 selection and data object, create a path to represent the edge described in d.label.

    If d.label is defined, it will be a RenderMetaedgeInfo instance. It will sometimes be undefined, for example for some Annotation edges for which there is no underlying Metaedge in the hierarchical graph.

    Parameters

    Returns void

buildGroup

  • Select or Create a 'g.edges' group to a given sceneGroup and builds a number of 'g.edge' groups inside the group.

    Structure Pattern:

    ...

    Parameters

    Returns any

    selection of the created nodeGroups

getEdgeKey

getEdgePathInterpolator

  • getEdgePathInterpolator(d: EdgeData, i: number, a: string): any
  • Returns a tween interpolator for the endpoint of an edge path.

    Parameters

    Returns any

getLabelForBaseEdge

getLabelForEdge

  • Creates the label for the given metaedge. If the metaedge consists of only 1 tensor, and it's shape is known, the label will contain that shape. Otherwise, the label will say the number of tensors in the metaedge.

    Parameters

    Returns string

position

  • position(d: any): void

stylize

  • stylize(edgeGroup: any, d: EdgeData, stylize: any): void
  • For a given d3 selection and data object, mark the edge as a control dependency if it contains only control edges.

    d's label property will be a RenderMetaedgeInfo object.

    Parameters

    • edgeGroup: any
    • d: EdgeData
    • stylize: any

    Returns void

Generated using TypeDoc