Graflume · Alpha
Vector field · Edge-case application
Encode direction and magnitude at each coordinate with arrow angle and length. Exercise numeric range, sparse structure, and large inputs with valid data. Each tab materializes data only when needed and never silently repairs invalid values.
Chart family · Specialized families
Vector field
Encode direction and magnitude at each coordinate with arrow angle and length.
- Quick API
vectorField()- Browser snapshot
graflume/complete- mark
vector- Presets
- 2
Edge cases
Numeric range, irregular structure, and data volume
Exercise numeric range, sparse structure, and large inputs with valid data. Each tab materializes data only when needed and never silently repairs invalid values.
Wide numeric range
Mix zero, very small finite values, and very large finite values to verify automatic domains, precision, and stable geometry. NaN and Infinity remain intentionally invalid. It applies 2 data-integrity rules that preserve finite values and axis domains.
StatusLoading
extreme-rangeextreme-smallextreme-largezeromixed-signbudget:marks<=6
Loading
Wide numeric range · Row data
Row data and zero-copy TypedArray columns share one data contract.
xquantitative | yquantitative | directionquantitative | magnitudequantitative | valuequantitative | highquantitative |
|---|---|---|---|---|---|
| -4 | -3 | -360 | 1e-09 | -1e+12 | -1e-09 |
| -3 | -3 | 0 | 0 | -1e-09 | 0 |
| -2 | -3 | 360 | 1e+12 | 0 | 1e+12 |
| -1 | -3 | 720 | 1 | 1e+12 | 1e-09 |
| 0 | -3 | 90 | 1e+06 | 1e-09 | 1e+06 |
| 1 | -3 | 270 | 1e-06 | 1e+06 | -1e+12 |
Browser API · Portable schema
Browser API
Graflume.vectorField()
const data = [
{
"direction": -360,
"high": -1e-9,
"magnitude": 1e-9,
"value": -1000000000000,
"x": -4,
"y": -3
},
{
"direction": 0,
"high": 0,
"magnitude": 0,
"value": -1e-9,
"x": -3,
"y": -3
},
{
"direction": 360,
"high": 1000000000000,
"magnitude": 1000000000000,
"value": 0,
"x": -2,
"y": -3
},
{
"direction": 720,
"high": 1e-9,
"magnitude": 1,
"value": 1000000000000,
"x": -1,
"y": -3
},
{
"direction": 90,
"high": 1000000,
"magnitude": 1000000,
"value": 1e-9,
"x": 0,
"y": -3
},
{
"direction": 270,
"high": -1000000000000,
"magnitude": 0.000001,
"value": 1000000,
"x": 1,
"y": -3
}
];
const options = {
"accessibility": {
"description": "A balanced vortex keeps direction, magnitude, and the calm center visible. The example uses curated, deterministic data and exposes its exact values in a semantic table.",
"label": "Vector field"
},
"height": 620,
"locale": "en",
"mark": {
"fields": {
"direction": "direction",
"magnitude": "magnitude"
}
},
"title": {
"subtitle": "edge case · range",
"text": "Vector field"
},
"width": "container",
"x": {
"field": "x",
"title": "Horizontal position",
"type": "quantitative"
},
"y": {
"field": "y",
"title": "Vertical position",
"type": "quantitative"
}
};
Graflume.vectorField('#chart', data, options);Portable schema
ChartSpec 0.1 · options
{
"accessibility": {
"description": "A balanced vortex keeps direction, magnitude, and the calm center visible. The example uses curated, deterministic data and exposes its exact values in a semantic table.",
"label": "Vector field"
},
"height": 620,
"locale": "en",
"mark": {
"fields": {
"direction": "direction",
"magnitude": "magnitude"
}
},
"title": {
"subtitle": "edge case · range",
"text": "Vector field"
},
"width": "container",
"x": {
"field": "x",
"title": "Horizontal position",
"type": "quantitative"
},
"y": {
"field": "y",
"title": "Vertical position",
"type": "quantitative"
}
}Sparse and irregular structure
Exercise only duplicate, missing, sparse, or out-of-order structures whose meaning is defined for this family. Broken references and malformed tuples are never disguised as successful examples. It applies 3 structural rules that preserve the meaning of missing, duplicate, and ordered values.
StatusLoading
irregular-structuresparseduplicate-pointangle-wrapzero-vectorbudget:marks<=7
Loading
Sparse and irregular structure · Row data
Row data and zero-copy TypedArray columns share one data contract.
xquantitative | yquantitative | directionquantitative | magnitudequantitative | valuequantitative | highquantitative |
|---|---|---|---|---|---|
| -4 | -3 | 310.267 | 2.228 | 1.44 | -1.7 |
| -3 | -3 | 322.357 | 1.998 | 1.582 | -1.22 |
| -4 | -3 | 310.267 | 2.228 | 1.44 | -1.7 |
| -2 | -3 | 335.932 | 1.815 | 1.657 | -0.74 |
| -1 | -3 | 350.937 | 1.651 | 1.63 | -0.26 |
| 0 | -3 | 8.269000000000005 | 1.53 | 1.514 | 0.22 |
| 1 | -3 | 27.187000000000012 | 1.532 | 1.363 | 0.7 |
Browser API · Portable schema
Browser API
Graflume.vectorField()
const data = [
{
"direction": 310.267,
"high": -1.7,
"magnitude": 2.228,
"value": 1.44,
"x": -4,
"y": -3
},
{
"direction": 322.357,
"high": -1.22,
"magnitude": 1.998,
"value": 1.582,
"x": -3,
"y": -3
},
{
"direction": 310.267,
"high": -1.7,
"magnitude": 2.228,
"value": 1.44,
"x": -4,
"y": -3
},
{
"direction": 335.932,
"high": -0.74,
"magnitude": 1.815,
"value": 1.657,
"x": -2,
"y": -3
},
{
"direction": 350.937,
"high": -0.26,
"magnitude": 1.651,
"value": 1.63,
"x": -1,
"y": -3
},
{
"direction": 8.269000000000005,
"high": 0.22,
"magnitude": 1.53,
"value": 1.514,
"x": 0,
"y": -3
},
{
"direction": 27.187000000000012,
"high": 0.7,
"magnitude": 1.532,
"value": 1.363,
"x": 1,
"y": -3
}
];
const options = {
"accessibility": {
"description": "A balanced vortex keeps direction, magnitude, and the calm center visible. The example uses curated, deterministic data and exposes its exact values in a semantic table.",
"label": "Vector field · Sparse and irregular structure"
},
"height": 620,
"locale": "en",
"mark": {
"fields": {
"direction": "direction",
"magnitude": "magnitude"
}
},
"title": {
"subtitle": "edge case · structure",
"text": "Vector field · Sparse and irregular structure"
},
"width": "container",
"x": {
"field": "x",
"title": "Horizontal position",
"type": "quantitative"
},
"y": {
"field": "y",
"title": "Vertical position",
"type": "quantitative"
}
};
Graflume.vectorField('#chart', data, options);Portable schema
ChartSpec 0.1 · options
{
"accessibility": {
"description": "A balanced vortex keeps direction, magnitude, and the calm center visible. The example uses curated, deterministic data and exposes its exact values in a semantic table.",
"label": "Vector field · Sparse and irregular structure"
},
"height": 620,
"locale": "en",
"mark": {
"fields": {
"direction": "direction",
"magnitude": "magnitude"
}
},
"title": {
"subtitle": "edge case · structure",
"text": "Vector field · Sparse and irregular structure"
},
"width": "container",
"x": {
"field": "x",
"title": "Horizontal position",
"type": "quantitative"
},
"y": {
"field": "y",
"title": "Vertical position",
"type": "quantitative"
}
}High data volume
Materialize a deterministic compact recipe only when this tab opens. Graflume's performance profile bounds mark count, hit testing, and animation work for the input size. It applies 6 high-volume rules for deterministic generation and bounded output. This family materializes 60,000 logical rows and bounds rendered point marks at 20,000.
StatusLoading
high-row-cardinalityall-input-rows-generatedall-input-rows-processeddeterministic-generationbounded-renderinginput:60000zoom-pan-resetbudget:point-marks<=20000
- Legend:
legend · explicit · 1 channels - Point and range highlights:
highlights[] · datum · x - Custom callouts:
annotations[] · datum · x · callout · placement:auto
Loading
Browser API · Portable schema
Browser API
Graflume.vectorField()
const recipe = {
"cardinality": {
"axes": {},
"sourceRows": 60000,
"unit": "rows"
},
"expectedInvariants": [
"finite-json",
"magnitude-nonnegative"
],
"id": "spatial-vector",
"initialView": {
"kind": "domain",
"zoom": 1
},
"outputBudget": {
"maximum": 20000,
"resource": "point-marks"
},
"parameters": {
"family": "vector-field",
"nullableFields": [],
"positiveFields": [
"magnitude"
],
"scenario": "volume",
"valueFields": [
"value",
"high"
],
"valuePolicy": "vector"
},
"preview": {
"maximumRows": 12,
"method": "spatial-slice"
},
"reduction": {
"method": "vector-grid-level-of-detail",
"stage": "level-of-detail"
},
"seed": 839683241,
"shape": "rows",
"version": 2
};
const { data, previewRows, plan } = Graflume.materializeDemoRecipe(recipe);
const options = {
"accessibility": {
"description": "Zoom and pan inspect the rendered surface without changing data axes or values. When playback controls are available, they move through real steps in the order each unique value first appears in the source data.",
"label": "Vector field · High data volume"
},
"annotations": [
{
"connector": {
"visible": true
},
"detail": "Attach user-authored safe text to a datum, axis range, or normalized plot position.",
"id": "manual-callout",
"placement": "auto",
"style": {
"maxWidth": 220,
"padding": 8
},
"target": {
"field": "x",
"type": "datum",
"value": -1.2623
},
"text": "Point and range highlights · -1.2623"
}
],
"create": {
"adaptive": {
"environment": {
"rowCount": 60000
},
"largeDataNavigation": true,
"profiles": "auto"
}
},
"height": 620,
"highlights": [
{
"id": "manual-focus",
"padding": 7,
"target": {
"field": "x",
"type": "datum",
"value": -1.2623
}
}
],
"interaction": {
"controls": {
"annotations": false,
"export": true,
"fullscreen": true,
"labels": {
"controls": "Chart controls",
"enterFullscreen": "Enter fullscreen",
"exitFullscreen": "Exit fullscreen",
"exportPng": "Download PNG",
"hideAnnotations": "Hide callouts",
"loop": "Loop playback",
"nextFrame": "Next frame",
"pause": "Pause",
"play": "Play",
"previousFrame": "Previous frame",
"reset": "Reset view",
"seek": "Playback position",
"showAnnotations": "Show callouts",
"speed": "Playback speed",
"zoomIn": "Zoom in",
"zoomOut": "Zoom out"
},
"playback": false,
"reset": true,
"zoom": true
},
"hover": true,
"navigation": {
"drag": true,
"keyboard": true,
"maxZoom": 6,
"minZoom": 1,
"pinch": true,
"wheel": "modifier"
},
"tooltip": {
"fields": [
{
"field": "x",
"format": "number",
"label": "X"
},
{
"field": "y",
"format": "number",
"label": "Y"
},
{
"field": "direction",
"format": "number",
"fractionDigits": 0,
"label": "Direction",
"suffix": "°"
},
{
"field": "magnitude",
"format": "number",
"label": "Magnitude"
},
{
"field": "value",
"format": "number",
"label": "Value"
},
{
"field": "high",
"format": "number",
"label": "High"
}
],
"title": "Vector field · High data volume",
"trigger": "mark"
}
},
"legend": {
"interactive": false,
"items": [
{
"id": "semantic-0",
"label": "Magnitude · length"
}
],
"labels": {
"hide": "Hide",
"show": "Show"
},
"maxItems": 8,
"mode": "layers",
"orientation": "horizontal",
"position": "bottom",
"title": "Vector field · High data volume",
"visible": true
},
"locale": "en",
"mark": {
"fields": {
"direction": "direction",
"magnitude": "magnitude"
}
},
"padding": {
"top": 52
},
"performance": "auto",
"theme": "graflume-light",
"title": {
"subtitle": "A balanced vortex keeps direction, magnitude, and the calm center visible · 60,000 logical rows, screen-aware detail",
"text": "Vector field · High data volume"
},
"width": "container",
"x": {
"field": "x",
"title": "Horizontal position",
"type": "quantitative"
},
"y": {
"field": "y",
"title": "Vertical position",
"type": "quantitative"
}
};
Graflume.vectorField('#chart', data, options);Portable schema
ChartSpec 0.1 · options
{
"accessibility": {
"description": "Zoom and pan inspect the rendered surface without changing data axes or values. When playback controls are available, they move through real steps in the order each unique value first appears in the source data.",
"label": "Vector field · High data volume"
},
"annotations": [
{
"connector": {
"visible": true
},
"detail": "Attach user-authored safe text to a datum, axis range, or normalized plot position.",
"id": "manual-callout",
"placement": "auto",
"style": {
"maxWidth": 220,
"padding": 8
},
"target": {
"field": "x",
"type": "datum",
"value": -1.2623
},
"text": "Point and range highlights · -1.2623"
}
],
"create": {
"adaptive": {
"environment": {
"rowCount": 60000
},
"largeDataNavigation": true,
"profiles": "auto"
}
},
"height": 620,
"highlights": [
{
"id": "manual-focus",
"padding": 7,
"target": {
"field": "x",
"type": "datum",
"value": -1.2623
}
}
],
"interaction": {
"controls": {
"annotations": false,
"export": true,
"fullscreen": true,
"labels": {
"controls": "Chart controls",
"enterFullscreen": "Enter fullscreen",
"exitFullscreen": "Exit fullscreen",
"exportPng": "Download PNG",
"hideAnnotations": "Hide callouts",
"loop": "Loop playback",
"nextFrame": "Next frame",
"pause": "Pause",
"play": "Play",
"previousFrame": "Previous frame",
"reset": "Reset view",
"seek": "Playback position",
"showAnnotations": "Show callouts",
"speed": "Playback speed",
"zoomIn": "Zoom in",
"zoomOut": "Zoom out"
},
"playback": false,
"reset": true,
"zoom": true
},
"hover": true,
"navigation": {
"drag": true,
"keyboard": true,
"maxZoom": 6,
"minZoom": 1,
"pinch": true,
"wheel": "modifier"
},
"tooltip": {
"fields": [
{
"field": "x",
"format": "number",
"label": "X"
},
{
"field": "y",
"format": "number",
"label": "Y"
},
{
"field": "direction",
"format": "number",
"fractionDigits": 0,
"label": "Direction",
"suffix": "°"
},
{
"field": "magnitude",
"format": "number",
"label": "Magnitude"
},
{
"field": "value",
"format": "number",
"label": "Value"
},
{
"field": "high",
"format": "number",
"label": "High"
}
],
"title": "Vector field · High data volume",
"trigger": "mark"
}
},
"legend": {
"interactive": false,
"items": [
{
"id": "semantic-0",
"label": "Magnitude · length"
}
],
"labels": {
"hide": "Hide",
"show": "Show"
},
"maxItems": 8,
"mode": "layers",
"orientation": "horizontal",
"position": "bottom",
"title": "Vector field · High data volume",
"visible": true
},
"locale": "en",
"mark": {
"fields": {
"direction": "direction",
"magnitude": "magnitude"
}
},
"padding": {
"top": 52
},
"performance": "auto",
"theme": "graflume-light",
"title": {
"subtitle": "A balanced vortex keeps direction, magnitude, and the calm center visible · 60,000 logical rows, screen-aware detail",
"text": "Vector field · High data volume"
},
"width": "container",
"x": {
"field": "x",
"title": "Horizontal position",
"type": "quantitative"
},
"y": {
"field": "y",
"title": "Vertical position",
"type": "quantitative"
}
}