Ask AI
Skip to main content

Add data point to Bar chart

Function: Add data point to Bar chart

This function allows you to dynamically add new data points to an existing Bar Chart element on your application page. This is incredibly useful for updating charts in real-time or based on user interactions, ensuring your data visualizations are always current without needing to refresh the entire page.

Input,

  • Bar chart UI element: (Type: UI element - Bar Chart) Select the specific Bar Chart component on your application page where you want to add the data.
  • Code: (Type: Text) Provide a unique identifier or name for the dataset within the chosen Bar Chart. For example, "Monthly Sales" or "Website Visitors". If a dataset with this code doesn't already exist in the chart, a new one will be automatically created.
  • Point: (Type: Text) Enter the actual data value you wish to add. This could be a number, a percentage, or any other relevant data point that the chart should display.

Output,

No direct output. The selected Bar Chart UI element on your application page will be visually updated with the new data point.

Execution Flow,

Real-Life Examples,

  1. Tracking Daily Sales Updates

    • Inputs:
      • Bar chart UI element: Sales Performance Chart
      • Code: Today's Revenue
      • Point: 1250.75
    • Result: The "Sales Performance Chart" will update to show a new data point of 1250.75 for the "Today's Revenue" dataset. If "Today's Revenue" didn't exist, a new bar representing this data would appear.
  2. Monitoring Website Visitor Count

    • Inputs:
      • Bar chart UI element: Live Website Traffic
      • Code: Current Users
      • Point: 345
    • Result: The "Live Website Traffic" chart will display an updated bar for "Current Users" showing 345 active visitors.
  3. Adding a New Product Category's Performance

    • Inputs:
      • Bar chart UI element: Product Sales by Category
      • Code: Electronics
      • Point: 7800
    • Result: A new dataset named "Electronics" will be created on the "Product Sales by Category" chart, displaying a bar with a value of 7800. If "Electronics" already existed, its bar would be updated with this new value.