We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
Syncfusion Feedback


Overview

The Xamarin.Forms pyramid chart is the form of a triangle with lines dividing it into sections, each section with a different width. Depending on the Y coordinates, this width indicates a level of hierarchy among other categories.

Beautiful Xamarin.Forms Pyramid Chart


Key features

Xamarin.Forms chart shows the different mode in pyramid chart

Pyramid mode

The pyramid chart supports two types of visualization mode, linear and surface. The Y value is represented by the height of the rectangle in linear mode and area of the rectangle in surface mode.

Xamarin.Forms chart shows the funnel segment gap

Segment gap

The segments in the pyramid chart can be separated by gaps to highlight the levels in the hierarchy.

Xamarin.Forms chart shows the exploded pyramid segment

Exploding on touch

Explode a single segment in the pyramid chart to differentiate it from others.

Xamarin.Forms pyramid chart shows the data labels

Data label

Show the detail about the data points with the help of data label support. Can place the label inside and outside of the chart. Use the connector line to connect the outside label with chart.


Code example

Easily get started with Xamarin Pyramid Chart using a few simple lines of C# code, as demonstrated below,

<?xml version="1.0" encoding="utf-8" ?>
<ContentPage xmlns="http://xamarin.com/schemas/2014/forms"
             xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
             xmlns:local="clr-namespace:ChartExample"
             xmlns:chart="clr-namespace:Syncfusion.SfChart.XForms;assembly=Syncfusion.SfChart.XForms"
             x:Class="ChartExample.MainPage">

    <ContentPage.BindingContext>
        <local:ViewModel/>
    </ContentPage.BindingContext>

    <chart:SfChart>

        <chart:SfChart.Series>
            <chart:PyramidSeries ItemsSource="{Binding Data}" XBindingPath="Month" YBindingPath="Target"/>
        </chart:SfChart.Series>

    </chart:SfChart>

</ContentPage>
public class Model
{
    public string Month { get; set; }

    public double Target { get; set; }

    public Model(string xValue, double yValue)
    {
        Month = xValue;
        Target = yValue;
    }
}

public class ViewModel
{
    public ObservableCollection<Model> Data { get; set; }

    public ViewModel()
    {
        Data = new ObservableCollection<Model>()
        {
            new Model("Jan", 50),
            new Model("Feb", 70),
            new Model("Mar", 65),
            new Model("Apr", 57),
            new Model("May", 48), 
        };
    }
}

Learning resources

Navigate to GitHub code used to configure the Xamarin.Forms pyramid chart

GitHub Code

Explore the Xamarin.Forms Pyramid Chart example from GitHub to learn how to render and configure charts.

Navigate to the options available in User Guide to customize the Xamarin.Forms pyramid chart

Pyramid Chart User Guide

Learn available options to customize the Xamarin.Forms pyramid chart.

Navigate to the API references documentation of Xamarin.Forms pyramid chart

Pyramid Chart API Reference

Explore the Xamarin.Forms pyramid chart APIs.


150+ XAMARIN UI CONTROLS

ALL CONTROLS
  • Xamarin.Forms
  • Xamarin.Android
  • Xamarin.iOS
The most downloaded control (based on the nuget.org download count).
Scroll up icon