Github url

metrics-graphics

by metricsgraphics

metricsgraphics /metrics-graphics

A library optimized for concise and principled data graphics and layouts.

7.2K Stars 521 Forks Last release: over 3 years ago (v2.11.0) Mozilla Public License 2.0 1.8K Commits 38 Releases

Available items

No Items, yet!

The developer of this repository has not created any items for sale yet. Need a bug fixed? Help with integration? A different license? Create a request here:

BundlePhobia CodeClimate Netlify Status

MetricsGraphics is a library built for visualizing and laying out time-series data. At around 15kB (gzipped), it provides a simple way to produce common types of graphics in a principled and consistent way. The library currently supports line charts, scatterplots and histograms, as well as features like rug plots.

Example

All you need to do is add an entry node to your document:

Then, use the id to mount the chart:

import LineChart from 'metrics-graphics' new LineChart({ data, // some array of data objects width: 600, height: 200, target: '#chart', area: true, xAccessor: 'date', yAccessor: 'value' })

That's it!

Sample Screenshot

The raw data for this example can be found here

Documentation

If you want to use MetricsGraphics, you can find the public API here.

If you want to extend MetricsGraphics, you can read up on the components and utilities.

We use cookies. If you continue to browse the site, you agree to the use of cookies. For more information on our use of cookies please see our Privacy Policy.