-
Notifications
You must be signed in to change notification settings - Fork 2
Home
Matplotlib-inspired charting for .NET — server-rendered SVG / PNG / PDF / animated-GIF output across 78 series types (line, scatter, bar, 3D, streaming, polar, financial, statistical, hierarchical, Sankey, vector), 13 map projections with embedded Natural Earth data, 26 themes, LaTeX-style MathText, O(1) streaming with 52 technical indicators (classical + volatility / momentum / trend / cycle / microstructure / entropy / change-point / cross-asset), financial drawing tools (trendlines, Fibonacci retracements, horizontal levels), frame-based animation with 6 easing curves + Pause/Resume playback, native UI controls for Blazor / WPF / MAUI / Avalonia / Uno Platform / ASP.NET Core, and TypeScript clients for Angular / React / Vue. Fluent API, DI-friendly, zero JavaScript framework, zero WebView, zero SaaS.
Current version: 1.10.0 · NuGet · Changelog · License: MIT
v1.10.0 is the Pair-Selection Visualisation Pack + NetworkGraphSeries — six chart-type slices in one release, the full machinery for correlation-based asset clustering, dimensional EDA, hierarchical risk parity, and lead-lag network analysis. Future releases are community-driven:
- 🗺️ Phase 1 — Annotated & triangular-mask heatmaps: four new
HeatmapSeriesproperties (ShowLabels,LabelFormat,MaskMode,CellValueColor) +HeatmapMaskModeenum; unblocks every realistic correlation-matrix figure. - 🌲 Phase 2 —
DendrogramSeries: hierarchical-clustering tree as canonical "U"-shape segments. FourDendrogramOrientationvalues; optionalCutHeightdraws a dashed reference line and recolours each cluster below the cut from a qualitativeIColorMap(defaultTab10). - 🔥 Phase 3 —
ClustermapSeries: composite heatmap with optional row/column dendrograms (the seabornclustermapidiom). Automatic data-matrix reordering to align cells visually with the leaf order. - 📊 Phase 4 —
PairGridSeries: multi-panel scatter matrix (the seabornpairplotidiom). N×N grid: histogram or KDE on the diagonal, scatter or hexbin on the off-diagonal, optional hue groups +string[]?HueLabelsfor category-aware EDA. - 🔷 Phase 5 — Hexbin off-diagonal: activates
PairGridOffDiagonalKind.Hexbin = 2for high-cardinality EDA where scatter overplots (~1000+ samples per cell). - 🕸️ Phase 6 —
NetworkGraphSeries: nodes-and-edges-in-2D for correlation networks (Pearson edge weights), lead-lag flow (TransferEntropy directed edges), Louvain community visualisation. FourGraphLayoutvalues:Manual,Circular,Hierarchical(BFS top-down with cycle handling),ForceDirected(Fruchterman–Reingold spring-embedder with seeded RNG + optional convergence-mode early-stop). DataFrame extensiondf.NetworkGraph(edgeFromCol, edgeToCol, weightCol:, directedCol:)derives nodes from the union of source/target columns. - 🐛 Bug fixes & coverage — driven by community use and the strict
≥90/90per-class coverage gate. - 🌱 Listening — Open a Discussion or Issue with what's missing for your use case. The next direction will be guided by what real users need, not by a feature checklist.
For release history, see the full CHANGELOG or the Roadmap.
MatPlotLibNet is built for .NET developers who need charting that fits naturally into their existing stack — no JavaScript framework, no third-party SaaS, no extra runtime.
| You are… | MatPlotLibNet gives you… |
|---|---|
| Blazor / ASP.NET Core developer | Drop-in <MplChart> and <MplLiveChart> components; SignalR push; REST endpoint — all wired with standard DI |
| Avalonia developer | Native MplChartControl via SkiaSharp — IsInteractive="True" for pan / zoom / reset / brush-select, no WebView |
| Uno Platform developer | Native MplChartElement via SkiaSharp — Windows, Android, iOS, macCatalyst from one codebase |
| MAUI developer | Native MplChartView control via Microsoft.Maui.Graphics — no WebView |
| Data scientist / analyst | Inline SVG in Polyglot Notebooks or Jupyter; 78 series types; MatPlotLibNet.DataFrame for plotting, 52 technical indicators (classical MAs + volatility / momentum / trend / cycle / microstructure / entropy / change-point / cross-asset families), and polynomial regression directly from Microsoft.Data.Analysis.DataFrame column names |
| Financial / trading app developer | Candlestick, OHLC, 52 technical indicators (SMA, EMA, RSI, MACD, Bollinger, Stochastic, ADX, Ichimoku — plus v1.8.0: Garman-Klass, Yang-Zhang, VPIN, BOCPD, Ehlers MAMA/FAMA, Laguerre RSI, Squeeze Momentum, wavelet entropy — plus v1.9.0: Supertrend, Klinger, Twiggs MF, Ease of Movement, VWAP Z-Score, CG Oscillator, Inverse Fisher, Ehlers iTrend, Decycler, SuperSmoother, Transfer Entropy), backtesting panels |
| Full-stack .NET + JS developer | TypeScript clients for Angular, React, and Vue — same SignalR hub, same chart definitions |
| Backend / headless pipeline | Render SVG, PNG, PDF, or animated GIF server-side with zero UI dependencies |
These are excellent WinForms / WPF / MAUI renderers. MatPlotLibNet targets the web and server first: SVG rendered on the server, pushed to any browser client over SignalR. No canvas, no WebAssembly boot cost, no browser rendering differences.
Plotly.NET emits JavaScript that runs in the browser. MatPlotLibNet renders entirely in .NET — the browser receives finished SVG. That means no JS dependency, consistent output, inline SVG in the DOM (CSS-styleable, accessible, print-quality), and rendering that scales with your server hardware.
Commercial libraries with per-developer or per-app licensing. MatPlotLibNet is MIT — free for any use, open-source or commercial, with no copyleft conditions.
| MatPlotLibNet | |
|---|---|
| Rendering | Server-side SVG — zero client cost |
| Output | SVG, PNG, PDF, JSON, animated GIF |
| Native controls |
MplChartControl (Avalonia 12), MplChartElement (Uno Platform) — SkiaSharp, no WebView |
| Real-time | SignalR push + streaming series with ring buffers, 11 incremental indicators, throttled re-rendering |
| Series types | 78 — including 12 3D, 4 streaming, polar, financial, hierarchical, Sankey, vector, network graph |
| Math text |
$\frac{a}{b}$, $\sqrt{x}$, $\hat{y}$, $\mathbb{R}$ — 96 symbol mappings |
| Performance | AVX SIMD coordinate transform, parallel subplot rendering |
| License | MIT — no copyleft, free for any use |
| Dependencies | Zero for SVG; SkiaSharp opt-in for PNG/PDF/GIF/native controls |
dotnet add package MatPlotLibNetPlt.Create()
.WithTitle("Hello MatPlotLibNet")
.Plot(x, y, s => { s.Color = Color.Blue; s.Label = "Data"; })
.WithLegend()
.Save("chart.svg");
| Resource | Contents |
|---|---|
| Playground | Try charts live in your browser — pick an example, change theme/size, see the SVG update instantly |
| Cookbook | Code examples with rendered images — copy, paste, chart |
| API Reference | Full API documentation generated from XML doc comments |
| Page | Contents |
|---|---|
| Getting Started | Installation, quick start, output formats (SVG/PNG/PDF/JSON/GIF) |
| Fluent Cheatsheet | One-page reference for Plt / FigureBuilder / AxesBuilder — |
| Package Map | All 13 NuGet packages + 3 JS packages explained |
| Notebooks | Polyglot Notebooks + Jupyter — inline SVG, Display(), tips |
| Chart Types | All 78 series types with code examples |
| Styling | Themes, colors, colormaps, rcParams, PropCycler |
| Advanced | Layouts, date axes, math text, animations, real-time charts |
| Streaming | ring buffers, StreamingFigure, axis scaling, 11 streaming indicators, platform controls |
| Interactive Controls | Avalonia + Uno native controls, managed interaction layer, server mode |
| Bidirectional SignalR | server-authoritative interactive charts, event hierarchy, FigureRegistry, hub wiring |
| Benchmarks | SVG rendering, SIMD transforms, indicators, JSON, PNG/PDF |
| Roadmap | Version history; v1.10.0 complete |
| Contributing | How to build, test, and contribute |
| Series types | 74 — line, scatter, bar, financial, statistical, 12 3D, 4 streaming, polar, hierarchical, Sankey, vector |
| Output formats | SVG (built-in), PNG, PDF, JSON, animated GIF |
| Platforms | .NET 10 / .NET 8, Blazor, Avalonia, Uno Platform, MAUI, ASP.NET Core, Angular, React, Vue, Jupyter |
| Native controls |
MplChartControl (Avalonia 12), MplChartElement (Uno/WinUI 3) — SkiaSharp, no WebView |
| Real-time | SignalR push + bidirectional interaction (zoom, pan, reset, legend toggle, brush-select, hover) |
| Math text | LaTeX-like inline math: $\frac{a}{b}$, $\sqrt{x}$, $\hat{y}$, $\mathbb{R}$, $\alpha^{2}$ — 96 symbol mappings |
| Date axes | Auto tick selection from years down to seconds |
| Layout | Constrained layout engine — auto-computes margins from text extents |
| Transform | AVX SIMD single-pass coordinate transform — up to 11.8× faster than naive |
| Packages | 13 NuGet + 3 npm — core, Skia, Blazor, AspNetCore, Avalonia, Uno, MAUI, DataFrame, Interactive, GraphQL, Notebooks |
| Tests | 5 385 tests across 9 test projects (post-1.7.1 uplift wave + Phase-9 dedup + 13-phase interaction-hardening behavioural harness + matplotlib-parity follow-on + Phase L defect closure + Phase M marker-renderer & new-tab wrap + Phase N magic-string elimination + enum contract tests + Phase O enum ordinal hardening + Phase P treemap expand/collapse + theme-distinctness consolidation) — including 146 dual-theme matplotlib fidelity tests pixel-verified against matplotlib 3.10.8 |