Data Visualization Widgets PieChart

A circular chart widget for web applications.

Included in: dx.chartjs.js, dx.all.js
PieChart interactive configuration
Copy code
$("#piechart").dxPieChart({
});

The dxPieChart widget is used to embed circular charts (such as pie or doughnut charts) into web applications.

You can create a widget using one of the following approaches.

  • jQuery
    Use the dxPieChart jQuery plug-in.

    HTML
    <div id="chartContainer"></div>
    JavaScript
    $("#chartContainer").dxPieChart({
        dataSource: dataSource,
        series: {
            argumentField: "country",
            valueField: "area"
        }
    });
  • Knockout
    Add a div element and apply the dxPieChart binding to this element.

    HTML
    <div data-bind="dxPieChart: {
        dataSource: dataSource,
        series: {
            argumentField: 'country',
            valueField: 'area'
        }
    }"></div>
  • Angular
    Add a div element and apply the dx-pie-chart directive to this element.

    HTML
    <div dx-pie-chart="{
        dataSource: dataSource,
        series: {
            argumentField: 'country',
            valueField: 'area'
        }
    }"></div>

Note that DevExtreme widgets require you to link the jQuery and Globalize libraries to your application. If you use the Knockout or Angular approach, the Knockout or Angular library is also required. For detailed information on how to link the needed libraries, refer to the Installation article.

To learn more about dxPieChart's visual elements, refer to the PieChart Elements help article. To learn how to provide data for the dxPieChart widget, refer to the Data Binding article.

Start Tutorial View Demo Watch Video

See Also

To learn the widget's concepts and overview features, refer to the Charts section within the Data Visualization Guides.

Configuration

An object that defines configuration options for the dxPieChart widget.

Methods

This section describes the methods that can be used in code to manipulate the dxPieChart object.

Use the dxPieChart registered method to access the dxPieChart object, as demonstrated in the code below.

var pieChart = $("#pieChartContainer").dxPieChart("instance");

Events

This section describes events fired by this widget.

Series Types

This section lists the objects that define options to be used to configure series of particular types.

Chart Elements

This section lists the methods and fields of the dxPieChart elements.