How To Add Charts And Graphs To WordPress
No doubt you’re familiar with the adage “a picture is worth a thousand words.” This is certainly true when you are trying to present or explain complex data.
Using graphs and charts is great for breaking up long chunks of text, and making technical or statistical data much easier to grasp.
You can use tables to present data, but if you want people to try and interpret complex information with numbers, percentages or comparisons easily, then charts and graphs are perfect for helping them visualize the data.
Graphs and charts help you present complex data so your audience can more easily understand it!
If you want to learn how to display information visually and dynamically on your WordPress site like graphs and charts, this step-by-step tutorial will show you how to create attractive and interactive charts to your pages that:
- Your site visitors can engage with
- Lets you upload chart or graph data from your computer or an online source of data
- Dynamically resizes for viewing on mobile devices
If you plan to display visual data like pie charts, comparison data or trending graphs containing static information (e.g. historical data), a simple method you can use to display this information is to create your graphs or charts using an image editing application, convert these into images and then simply insert the files and an image into your page or post.
Use WordPress Chart & Graph Plugins
If you want to embed interactive bar charts and graphs into WordPress with no coding skills required, the easiest way to do this is to use a plugin.
Fortunately, there is a great WordPress plugin that is simple to install, easy-to-use and allows you to not only create beautiful and dynamic charts and graphs, it also lets you populate your charts and graphs with dynamic data.
WP Plugin: Visualizer
Visualizer URL
You can install the plugin in your WP dashboard (we will show you how to do this further below), or download the Visualizer plugin the WP plugin repository using the link below:
http://wordpress.org/plugins/visualizer
Plugin Description
Visualizer is a simple, easy to use and powerful plugin for WordPress that lets you create, manage and embed attractive and mobile-responsive graphs and charts into your WordPress posts and pages with just a few simple steps.
WordPress Visualizer uses Google Visualization API to render charts, which support cross-browser compatibility (adopting VML for older IE versions) and cross-platform portability to iOS and new Android releases, and are based on pure HTML5/SVG technology (adopting VML for old IE versions), so no extra add-ons are required.
WordPress Visualizer also provides a variety of built-in that are optimized to address your data visualization needs, including:
- Line chart
- Area chart
- Bar chart
- Column chart
- Pie chart
- Geo chart
- Gauge chart
- Candlestick chart
- Scatter chart
The plugin is also flexible and customizable, allowing you to use Google Chart Tools with their default setting, or configure an extensive set of options to match your site’s design. Several options are available for each chart that allow you to customize their settings.
Additionally, charts are rendered using HTML5/SVG technology to provide cross-browser compatibility (including VML for older IE versions) and cross platform portability to iPhones, iPads and Android devices. Your visitors can see your charts and graphs on their mobile browsers without requiring the installation of any extra software.
How To Install Visualizer
From your WordPress dashboard, select Plugins > Add New from the main admin menu …
In the Add Plugins page type “visualizer” into the search field and hit enter …
Locate Visualizer in the search results section and click the “Install Now” button …
Click OK to proceed …
Activate the plugin …
You can also activate the plugin in the Plugins area …
Once the plugin has been activated, click on Library …
You can get to the plugin’s ‘library’ screen by choosing Media > Visualizer Library from the main menu …
This takes you to the plugin’s Visualizer Library screen …
When you first install the plugin, this section will be empty.
The next step is to add the charts and graphs to your library that you will want to publish to your content.
Visualizer Plugin Configuration
To add a new graph or chart to the plugin’s library, click on ‘Add New’ …
An image gallery displaying all of the different kinds of charts and graphs available will come up on your screen.
Select the type of graph or chart you would like to create and click on the ‘Next’ button …
Your graph/chart type will open up in a lightbox.
The next step is to upload a CSV file containing all the data you would like your chart or graph to be populated with …
When creating your CSV data file, ensure that:
- The first row contains the column headings.
- The second row contains the series type (e.g. number, datetime, etc.)
The screenshot below shows how to format your data as explained above …
If you are not sure how to format your CSV file, simply use the sample file supplied with the plugin.
Next, select your data source (‘From Computer’ or ‘From Web’) in the ‘Upload CSV File’ section.
Upload CSV File From Computer
To upload the CSV file from your computer select ‘From Computer‘ …
Locate and select your data file and then click on ‘Open‘ …
The plugin imports the data from the CSV file and displays it using the graph/chart type you have selected …
Upload CSV File From The Web
To learn how to create, save and publish data to a Visualizer chart or graph using Google Spreadsheet, see the article below:
After importing the data, make sure that all of the information is correct (if not, click on the ‘Back’ button and reupload a data file with the right data), and click ‘Next‘ …
Depending on the chart or graph type you have chosen, the plugin displays various customization options …
Visualizer gives you total control of your chart or graph, and updates your display in real time …
For example, the pie chart offers various configurable options, including:
- General Settings – Configure settings for the chart’s title, font styles, tooltip, and legend.
- Pie Settings – Create 3D pie charts, draw slices counterclockwise, set the text content displayed on the slice, create a “donut” pie chart, rotate the chart’s “start” angle and set the slice border color.
- Residue Settings – Set the ‘Visibility Threshold’ (the slice relative part, below which a slice will not show individually.), ‘Residual Slice Label’ (the label for the combination slice that holds all slices below slice visibility threshold, e.g. “Other”), and ‘Residue Slice Color’.
- Slice Settings – Customize the ‘Slice Offset’ (how far to separate the slice from the rest of the pie), and ‘Slice Color’.
- Layout & Chart Area – Configure the layout (total size of chart) including the width and height of the chart as a number of percentage, background color for the main area of the chart and the chart border width and color, and the placement and size of the chart area (where the chart itself is drawn, excluding axis and legends).
Once you are happy with the look of your graph or chart, click on the ‘Create Chart’ button …
The chart or graph will now be added to your Visualizer ‘Library’ …
Note that each visual element is given a unique ID displayed as a shortcode. As you will see in a moment, this lets you embed graphs and charts into your WordPress pages and posts easily and quickly …
Graphs and charts added to the Visualizer Library can easily be accessed by type …
After adding an element to the ‘Visualizer Library’, you can edit it, duplicate it, or trash it …
Visualizer Usage
After creating a new graph or chart and adding it to Visualizer, it’s easy to add it to posts and pages.
First, create a new post or page (or open an existing one) …
Next, place your mouse cursor where you would like to insert your visual element into the content and click on the ‘Add Media‘ button …
Click on ‘Visualizations‘ …
Select the chart or graph you want to insert into your content and click on the “insert” icon …
This will add a shortcode for the element into your content …
Once you have finished adding the item, click on Publish to publish (or update) your content …
After your post/page has been published, click ‘View post’ to see the result …
Your post or page displays your visual element in your content …
As mentioned earlier, the plugin also displays responsive charts for mobile viewing …
As you can see, Visualizer allows you to insert and customize dynamic charts and graphs in your content. You can change your data and your changes will automatically be reflected throughout your site. This makes adding dynamic graph information in WordPress very easy.
The developers of this plugin have created a number of tutorials you can use to learn how to edit, customize and use the Visualizer plugin for WordPress.
For additional tutorials on editing, copying, deleting and adding data to your charts, refer to the site below:
Congratulations! Now you know how to easily insert great-looking and dynamic pie charts and graphs into your WordPress posts and pages.
***
"Wow! I never knew there's so much to learn about WordPress! I bought one of the WordPress for Dummies three years ago, such authors need to be on this course!" - Rich Law, Create A Blog Now
***