Skip to content

Sociogram

Bryan Fox edited this page Nov 16, 2018 · 5 revisions

Purpose

Behaviors

General Interface API

See General Interface API.

Interface Specific API

In addition to all properties specified in the general interface API, this interface has the following parameters:

Example configuration

{
      "id": "sociogram",
      "type": "Sociogram",
      "label": "Sociogram",
      "prompts": [
        {
          "id": "closeness1",
          "text": "Position the nodes amongst the concentric circles. Place people you are closer to towards the middle",
          "subject": {
            "entity": "node",
            "type": "person"
          },
          "filter": "return operator.or([\nselect.edge({ type: 'friend' }),\nselect.alter({ type: 'person', attribute: 'age', operator: 'GREATER_THAN', value: 29 })]);",
          "layout": {
            "layoutVariable": "closenessLayout",
            "allowPositioning": true
          },
          "edges": {
            "display": ["friends", "professional"],
            "create": "friends"
          },
          "highlight": {
            "variable": "has_given_advice",
            "allowHighlighting": true
          },
          "disable": "return operator.or([\nselect.edge({ type: 'friend' }),\nselect.alter({ type: 'person', attribute: 'age', operator: 'LESS_THAN', value: 29 })]);",
          "sortOrder": [
            {
              "property": "nickname",
              "direction": "desc"
            }
          ],
          "background": {
            "concentricCircles": 4,
            "skewedTowardCenter": true
          }
        }
      ]
    }