Security News
RubyGems.org Adds New Maintainer Role
RubyGems.org has added a new "maintainer" role that allows for publishing new versions of gems. This new permission type is aimed at improving security for gem owners and the service overall.
ag-charts-community
Advanced tools
Advanced Charting / Charts supporting Javascript / Typescript / React / Angular / Vue
The ag-charts-community npm package is a powerful charting library that allows developers to create a wide variety of charts for data visualization. It is part of the AG Grid ecosystem and provides a flexible and customizable way to represent data graphically.
Line Chart
This feature allows you to create a basic line chart. The code sample demonstrates how to set up the data and series for a line chart.
const options = { data: [{ x: 0, y: 0 }, { x: 1, y: 1 }, { x: 2, y: 4 }, { x: 3, y: 9 }], series: [{ type: 'line', xKey: 'x', yKey: 'y' }] }; agCharts.AgChart.create(options);
Bar Chart
This feature allows you to create a bar chart. The code sample shows how to configure the data and series for a bar chart.
const options = { data: [{ category: 'A', value: 30 }, { category: 'B', value: 80 }, { category: 'C', value: 45 }], series: [{ type: 'bar', xKey: 'category', yKey: 'value' }] }; agCharts.AgChart.create(options);
Pie Chart
This feature allows you to create a pie chart. The code sample illustrates how to set up the data and series for a pie chart.
const options = { data: [{ label: 'A', value: 30 }, { label: 'B', value: 70 }], series: [{ type: 'pie', angleKey: 'value', labelKey: 'label' }] }; agCharts.AgChart.create(options);
Scatter Plot
This feature allows you to create a scatter plot. The code sample demonstrates how to configure the data and series for a scatter plot.
const options = { data: [{ x: 5, y: 10 }, { x: 15, y: 20 }, { x: 25, y: 30 }], series: [{ type: 'scatter', xKey: 'x', yKey: 'y' }] }; agCharts.AgChart.create(options);
Chart.js is a popular open-source library for creating simple yet flexible charts. It offers a variety of chart types and is known for its ease of use and integration. Compared to ag-charts-community, Chart.js is more lightweight but may lack some of the advanced customization options.
Highcharts is a well-known charting library that provides a wide range of chart types and extensive customization options. It is highly versatile and supports complex data visualizations. Highcharts is more feature-rich compared to ag-charts-community but comes with a steeper learning curve and licensing costs for commercial use.
D3.js is a powerful JavaScript library for producing dynamic, interactive data visualizations in web browsers. It uses web standards such as SVG, HTML, and CSS. D3 offers unparalleled flexibility and control over the visualizations but requires a deeper understanding of web technologies and data manipulation compared to ag-charts-community.
AG Charts is a fully-featured and highly customizable canvas-based JavaScript Charting library. It delivers outstanding performance, has no third-party dependencies, and comes with support for React , Angular and Vue .
AG Charts is available in two versions: Community & Enterprise.
ag-charts-community
is free, available under the MIT license, and comes with core series types, such as Pie, Area, Bar, Scatter and Bubble in addition to all of the key features expected from a JavaScript charting library, including Accessibility, Tooltips, Themes, Markers, Legends, Axis Types and Secondary Axes.ag-charts-enterprise
is available under a commercial license and comes with additional series types, such as Maps, Sankey, Radar, and Waterfall Charts as well as advanced interactivity features, like Animations, Context Menus, Zooming, Navigators, Synchronization and much more, including Financial Charts.AG Charts offers 20+ JavaScript Chart types, each of which are fully customisable:
Chart Type | AG Charts Community | AG Charts Enterprise |
---|---|---|
Bar | ✅ | ✅ |
Line | ✅ | ✅ |
Area | ✅ | ✅ |
Scatter | ✅ | ✅ |
Bubble | ✅ | ✅ |
Pie | ✅ | ✅ |
Donut | ✅ | ✅ |
Combination | ✅ | ✅ |
Box Plot | ❌ | ✅ |
Bullet | ❌ | ✅ |
Candlestick | ❌ | ✅ |
OHLC | ❌ | ✅ |
Heatmap | ❌ | ✅ |
Histogram | ❌ | ✅ |
Nightingale | ❌ | ✅ |
Radar Line | ❌ | ✅ |
Radar Area | ❌ | ✅ |
Radial Column | ❌ | ✅ |
Radial Bar | ❌ | ✅ |
Range Area | ❌ | ✅ |
Range Bar | ❌ | ✅ |
Sunburst | ❌ | ✅ |
Treemap | ❌ | ✅ |
Waterfall | ❌ | ✅ |
Sankey | ❌ | ✅ |
Chord | ❌ | ✅ |
AG Charts JavaScript Charting Library comes with every feature you'd expect:
Feature | AG Charts Community | AG Charts Enterprise |
---|---|---|
Accessibility | ✅ | ✅ |
Localisation | ✅ | ✅ |
Series Highlighting | ✅ | ✅ |
Tooltips | ✅ | ✅ |
Animations | ❌ | ✅ |
Context Menu | ❌ | ✅ |
Crosshairs | ❌ | ✅ |
Navigator | ❌ | ✅ |
Synchronization | ❌ | ✅ |
Zoom | ❌ | ✅ |
ℹ️ Note:
Visit the Pricing page for a full comparison.
Build interactive financial charts featuring advanced annotations with minimal configuration, all you need to do is provide your data:
const options = {
data: getData(),
};
AgCharts.createFinancialChart(options);
Once created, users will have a Financial Chart that they can interact with and add annotations to.
The default chart type is Candlestick, with additional types like OHLC and Line for versatile data visualisation.
The Maps Series let you visualise geographic data in different ways.
Maps can display data using Shapes, Lines and Marker series:
const options = {
topology: topology,
series: [
{
type: 'map-shape',
data: pacific,
idKey: 'name',
title: 'Pacific',
},
// ...
],
legend: {
enabled: true,
},
// ...
};
AG Charts are easy to set up - all you need to do is provide your data and series type along with any other chart options. Read on for vanilla JavaScript installation instructions, or refer to our framework-specific guides for React, Angular and Vue.
$ npm install ag-charts-community
<!doctype html>
<html lang="en">
<head>
<title>AG Charts Quick Start</title>
<!-- JavaScript Charts Core Library -->
<script src="https://cdn.jsdelivr.net/npm/ag-charts-community/dist/umd/ag-charts-community.js"></script>
</head>
<body>
<!-- Container for Chart -->
<div id="myChart"></div>
<!-- Charts configuration file -->
<script src="index.js"></script>
</body>
</html>
// Chart Options
const options = {};
// Create Chart
const chart = agCharts.AgCharts.create(options);
// Chart Options
const options = {
// Container: HTML Element to hold the chart
container: document.getElementById('myChart'),
// Data: Data to be displayed in the chart
data: [
{ month: 'Jan', avgTemp: 2.3, iceCreamSales: 162000 },
{ month: 'Mar', avgTemp: 6.3, iceCreamSales: 302000 },
{ month: 'May', avgTemp: 16.2, iceCreamSales: 800000 },
{ month: 'Jul', avgTemp: 22.8, iceCreamSales: 1254000 },
{ month: 'Sep', avgTemp: 14.5, iceCreamSales: 950000 },
{ month: 'Nov', avgTemp: 8.9, iceCreamSales: 200000 },
],
// Series: Defines which chart type and data to use
series: [{ type: 'bar', xKey: 'month', yKey: 'iceCreamSales' }],
};
ℹ️ Note:
For more information on building JavaScript Charts with AG Charts, refer to our Documentation.
AG Charts Enterprise customers have access to dedicated support via ZenDesk, which is monitored by our support & engineering teams.
If you have found a bug, please report it in this repository's issues section.
Look for similar problems on StackOverflow using the ag-charts
tag. If nothing seems related, post a new message there. Please do not use GitHub issues to ask questions.
AG Charts is developed by a team of co-located developers in London. If you want to join the team send your application to info@ag-grid.com.
ag-charts-community
is licensed under the MIT license.
ag-charts-enterprise
has a Commercial license.
See the LICENSE file for more info.
AG Grid is our flagship product, a fully-featured and highly customizable JavaScript Data Grid. It delivers outstanding performance, has no third-party dependencies and comes with support for React, Angular and Vue.
AG Charts is used within AG Grid to power the Integrated Charting feature.
Learn more at ag-grid.com
FAQs
Advanced Charting / Charts supporting Javascript / Typescript / React / Angular / Vue
The npm package ag-charts-community receives a total of 145,927 weekly downloads. As such, ag-charts-community popularity was classified as popular.
We found that ag-charts-community demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
RubyGems.org has added a new "maintainer" role that allows for publishing new versions of gems. This new permission type is aimed at improving security for gem owners and the service overall.
Security News
Node.js will be enforcing stricter semver-major PR policies a month before major releases to enhance stability and ensure reliable release candidates.
Security News
Research
Socket's threat research team has detected five malicious npm packages targeting Roblox developers, deploying malware to steal credentials and personal data.