Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Proposing New Component - Pie Chart with Filter - Areteans #98

Open
s-thutupalli opened this issue Nov 27, 2024 · 2 comments
Open

Proposing New Component - Pie Chart with Filter - Areteans #98

s-thutupalli opened this issue Nov 27, 2024 · 2 comments
Labels
question Further information is requested

Comments

@s-thutupalli
Copy link

Title: Pie Chart with Filter

Overview

The Pie Chart React Component with Filtering Options is a versatile data visualization tool that allows users to display data distributions in a pie chart format. This component comes with dynamic filtering options, enabling users to focus on specific data subsets by selecting or excluding certain columns or categories. It's designed to handle both static and dynamic datasets.

It is ideal for applications where users need to visualize proportional data and refine views based on specific column criteria.

Usage

This component can be used for data visualizations with which the users can drilldown the data for the specific columns to retrieve better data insights.

Component’s key features include

Dynamic Data Rendering: Accepts data in a tabular format (e.g., JSON or arrays) to generate pie charts dynamically.

Column Filtering Options: Provides UI elements (dropdowns, checkboxes, or sliders) for users to filter data based on specific column values.

Interactive Updates: Automatically updates the chart when filters are applied.

Custom Tooltip: Provide detailed information on hover.

Configurations:

chartTitle – to display the label to indicate what the chart data represents.

dataPageName – datapage reference which will be the source for the chart data.

chartDataColumns– comma separated values to indicate the 2 columns to be used for pie chart.

filterColumns – comma separated values which will be used as dynamic filters for chart drill downs.

Dependencies:

  1. React Google Charts

    npm install react-google-charts

  2. Material-UI (MUI)

    npm install @mui/material @emotion/react @emotion/styled

Component benefits

1. Enhanced Data Visualization –

A pie chart offers an intuitive way to visualize proportions and compare categories briefly.

Data filters allow users to focus on specific segments or time periods, making the chart more relevant.

2. Improved User Interactivity –

Users can apply filters on columns to customize the displayed data, creating a more interactive experience.

Filters enable users to dive deeper into specific data subsets, uncovering hidden insights.

3. Real-Time Data Insights - For dashboards or live analytics, filtered pie charts can update dynamically to reflect the latest data, ensuring up-to-date insights.

4) Example Use Cases
a) E-commerce: Visualizing sales distribution across product categories with filters for regions or time periods.
b) Finance: Analysing expense categories with filters for months or departments.
c) Marketing: Displaying campaign performance by segment with filters for demographics or platforms.

Attached the component code and detailed description with images below.

Custom_Pie_Chart_Filter.docx
CustomPieChart.zip

@ricmars
Copy link
Collaborator

ricmars commented Dec 1, 2024

this component is not following the best practices for this github repo - see https://pegasystems.github.io/constellation-ui-gallery/?path=/docs/support-and-contributing--docs:

  • the component does not use the Constellation presentational component and instead requires material UI
  • The chart is rendering using react google chart but such type of insight is already available in constellation

Why build a Constellation DX component when this UX pattern can be achieved using a dashboard with promoted filters and an insight?

@ricmars ricmars added the question Further information is requested label Dec 1, 2024
@s-thutupalli
Copy link
Author

We are working on your comments, will get back to you on this as soon as possible.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants