Skip to content

Scientific Bundle (velo-plot/scientific)

Focused bundle for scientific and specialized visualization. Excludes trading-only plugins (drawings, replay, alerts) while including analysis, 3D, and extended series.

~114 KB gzip (minified ESM). Importing this entry runs registerScientific.ts, which registers extended series buffers, frame renderers, overlay drawers, heatmap shaders, WebGPU hook, and SVG export.

Import

typescript
import {
  createChart,
  createStackedChart,
  Series,
  PluginAnalysis,
  PluginForecasting,
  PluginLaTeX,
  Plugin3D,
  PluginRegression,
  PluginBrokenAxis,
  PluginVirtualization,
  LinearScale,
  DARK_THEME,
} from 'velo-plot/scientific'

What you get vs core

CategoryIncluded
Seriesbar, heatmap, polar, boxplot, waterfall, gauge, sankey (+ all core types)
Exportchart.exportSVG() (sync, patched)
Rendererrenderer: 'webgpu' opt-in
StackedcreateStackedChart
AnalysisPluginAnalysis, FFT, peaks, integration — standalone utils via velo-plot/plugins/analysis or re-exported from scientific
Math / fitPluginRegression, PluginForecasting
LabelsPluginLaTeX
3DPlugin3D and 3D renderer exports
LayoutPluginBrokenAxis, PluginVirtualization
ThemesExtended theme set (MIDNIGHT_THEME, ELECTROCHEM_THEME, …)

What is excluded (use trading entry)

FeatureImport instead
chart.addIndicator() presetsvelo-plot/trading
Price alerts, position linesvelo-plot/trading
PluginDrawingTools, PluginReplayvelo-plot/trading
Heikin-ashi, business-day scalevelo-plot/trading
Datafeed / mock OHLCVvelo-plot/trading

For apps that need both trading and scientific features, use velo-plot/full.

Financial indicators

Functions like sma, ema, and rsi are not re-exported from the main scientific entry. Import them from velo-plot/plugins/analysis or use velo-plot/full.

Extended series example

typescript
import { createChart } from 'velo-plot/scientific'

const chart = createChart({ container })

chart.addSeries({
  id: 'density',
  type: 'heatmap',
  data: { /* xValues, yValues, zValues */ },
  style: { colorScale: { name: 'viridis' } },
})

Analysis plugins

typescript
import { createChart, PluginAnalysis } from 'velo-plot/scientific'

const chart = createChart({ container })
const analysis = chart.use(PluginAnalysis())

// Plugin API available on chart.analysis after init

See Scientific Analysis guide and Analysis API.

3D

typescript
import { Plugin3D } from 'velo-plot/scientific'

chart.use(Plugin3D({ /* … */ }))

See 3D Getting Started.

Registration

Like trading, the scientific entry performs side-effect registration on import:

typescript
// src/scientific/index.ts
import './registerScientific'

registerScientific calls registerExtendedSeries() + patchExportSVG(). It does not patch trading chart methods.

Bundle size

MetricValue
Gzip (minified ESM)~114 KB
CI budget200 KB
vs core-only+~63 KB

Known limitations

  • Trading-only APIs (addIndicator, alerts, drawings) are not included — use velo-plot/trading or /full for those.
  • Import side-effects register extended series — always import from velo-plot/scientific, not deep paths.

Released under the MIT License.