Skip to main content
100%

Magic Bar Chart

✓ Published0🌍 Public
CCurran Kelleher
Last edited Dec 8, 2015
Created on Sep 23, 2015

This interactive bar chart, built with SVG and powered by a Chiasm + AngularJS architecture, lets users explore UCI Machine Learning datasets. Users select a dataset, choose a column to visualize, and adjust orientation and color via linked widgets. For numeric columns, values are binned into histograms; categorical columns produce bars for each unique value. The visualization reads data such as the adult census data, illustrating that changing the data or encoding triggers declarative configuration updates that the Chiasm runtime applies by diffing against the previous state. Note that tick labels may overlap on dense axes.

AI-generated description

This example shows one way to add a user interface on top of a Chiasm application (using AngularJS). Every time an interaction is performed with the widgets on the left, a new Chiasm configuration is generated and passed into the Chaism runtime environment. The runtime environment then computes the difference between the previous configuration and the new configuration, then executes actions corresponding to the changes to the appropriate component instances.

Features of this example include:

  • Selection from three preselected data sets from the UCI Machine Learning Repository
  • Selection of a single column from the selected data set to visualize in the bar chart.
    • Numeric columns will be aggregated into bins and presented as a histogram.
    • Categorical columns will be aggregated and presented as a bar chart, where each bar corresponds to a unique value.
  • Selection of bar chart orientation between horizontal and vertical.
  • Selection of bar fill color.

Known Issues (e.g. with the "adult" data set):

  • The tick labels overlap each other on the X axis in many cases
  • The tick labels overlap with the axis label on the Y axis

Draws from

<!-- Start of SimpleHitCounter Code --> <div align="center"><a href="http://www.simplehitcounter.com" target="_blank"><img src="http://simplehitcounter.com/hit.php?uid=1957110&f=16777215&b=0" border="0" height="18" width="83" alt="web counter"></a></div> <!-- End of SimpleHitCounter Code -->

Similar vizzes

Loading thumbnail…

Magic Bar Chart

This example demonstrates a Magic Bar Chart, a reusable visualization component built with Chiasm and bundled with Browserify for production use. The chart animates the transition of bar positions and heights based on changing data, rendering smooth, dynamic updates with SVG. The visualization reads from the `adult.csv` dataset, which contains demographic records including age, education, occupation, and income category. The chart likely groups or aggregates this data by income category and animates between different categorical groupings (such as sex, race, or workclass) using Chiasm's reactive dataflow. The SVG-based rendering and animation make the bar chart transitions fluid, providing an interactive and engaging way to explore the dataset. The example demonstrates how Chiasm can be used to build a reusable, production-ready data visualization component.# Magic Bar Chart This example demonstrates a reusable bar chart built with Chiasm and bundled using Browserify. It visualizes the UCI Adult dataset, showing income distributions across demographic categories. The chart uses animated SVG transitions to smoothly morph between different data groupings, making it easy to compare income patterns across attributes like education, occupation, and native country. The visualization showcases how Chiasm's reactive dataflow architecture enables clean, maintainable visualization code in production environments. The "magic" refers to the chart's ability to automatically update and animate when the underlying data or configuration changes. ---

CCurran Kelleher
88% match