Updating map image coordinates via API
This demo shows how you can dynamically update coordinates of the map image. We’re going to have a loop to create a basic animation of moving a simple circle from Vienna to Rio. If we want to move an...
View ArticleUsing amCharts WordPress plugin
WordPress being the single most used web publishing platform, is perfect for when you want your website up and running in minutes. However, when it comes to dynamic content, such as JavaScript, you’ll...
View ArticleTransferring demos from amcharts.com, CodePen or jsFiddle into WordPress
Most of the amCharts demos you find will be shown on either amcharts.com demo section, CodePen or jsFiddle websites. This tutorial focuses on how to easily transfer them into your WordPress website....
View ArticleAngular Gauge with Two Axes
This demo shows how you can add multiple axes to the Angular Gauge chart. The inner circle is achieved using an axis with small radius coinciding with arrow’s innerRadius so it looks like a hollow base...
View ArticleDisplay the last value of the graphs on value axis in Stock Chart
This demo uses AmCharts.addInitHandler() to set up a custom function, that gets executed before chart is initialized. The function examines last data point for each of available graphs in each panel,...
View ArticleSelecting countries on a map
This demo shows how you can use JavaScript Maps’ clickMapObject event to create a map with togglable countries. The event handler dynamically sets showAsSelected property, without reloading the whole...
View ArticlePre-selecting areas on a map using array of country ISO2 codes
This demo shows how you can “pre-select” countries on a map, if you have a list of their codes as a JavaScript array. It uses JavaScript Maps’ init event to execute a special function which goes...
View ArticleSimulating double-click on GANTT chart segment
This demo shows how you can use clickGraphItem event to register both click and double-click events on GANTT chart segments. It works by delaying execution of click event using JavaScript function...
View ArticleAutomatically create state labels and callouts with values
This demo shows how you can automatically create labels over states with their values, as well as callouts for smaller states. Label is a MapImage object. The post Automatically create state labels and...
View ArticleOrder stacked columns by their value within each category
Technically, there is no way to order stacked columns within each category individually. Each column segment will come in the same order as they are defined in graphs array. This demo shows how to work...
View ArticleOptimizing multi-chart, periodically-updated dashboards
Problem Having a lot of charts on the same page can put a significant strain on the browser. Especially if those charts are updated dynamically. Typically, in dynamic dashboards, you’d update chart’s...
View ArticleSerial chart with clickable links in rollover balloons
Normally the links in rollover balloons are not clickable because the chart disables it. To re-enable interactivity with contents of the balloon, such as links, set balloon’s property...
View ArticleRemoving the outline from Pie chart slices
Normally, pie chart displays a small white outline around slices. You can change the outline color using outlineColor property. However, if you don’t want to show any outline at all, you can simply set...
View ArticleShowing one balloon per column stack
The post Showing one balloon per column stack appeared first on amCharts.
View ArticleDisplaying an automatically-generated table of data synced with category axis
This demo will show how you can use AmCharts.addInitHandler() to automatically generate a table out of the data below the chart. The code in handler – that is executed before the chart loads – will...
View ArticlePre-zooming chart’s value axis on chart load
The chart’s value axis can be zoomable. To enable zooming of the value axis, simply add valueScrollbar into your chart config. If you also want the value axis to load pre-zoomed to certain values, use...
View ArticleSimulating box plot with candlestick and floating column graphs
This demo shows how you can simulate a box plot chart using overlaid candlestick and three separate floating column graphs. Column graphs represent the three horizontal dividers for middle, high and...
View ArticleShowing countries on a World map selectively
If you need only some of the countries shown on the map, you can hide the other ones by setting unlistedAreasAlpha to zero. Add the ids of the areas you want to be shown to areas array, leave out the...
View ArticleSync chart cursor with HTML5 audio
This demo shows how you can sync an audio track from HTML5 tag <audio> with a chart. We’re using audio element’s timeupdate event to invoke chart cursor’s showCursorAt() method to place chart...
View ArticleLazy-loading 120 charts on the same page
This demo shows how you can build a “smart scroll” jQuery plugin that would start initializing the chart only when it scrolls into view. Having many charts on the same page might essentially bog down...
View Article