item explorer - data format - example 4
This example demonstrates how the item explorer visualization assigns different dimensions to items, separating purchases by item type and by payment method. The data is loaded from the CSV file `items_5d.csv`, and each dimension produces its own chart with a distinct x-axis label. The code uses the D3.js library, specifically the `itemExplorerChart` function, to render the visualization, with the chart appended to the body via `d3.select`. The CSV format encodes dimensions using the `:DI=` suffix, as shown in the header. Sorting is applied per dimension, and the example highlights how multiple dimensions can be visualized simultaneously.
AI-generated descriptionAn example of the required format for item explorer. This example shows how to use dimensions. Introducing different dimensions for the items typically means that each dimension is refering to something different. In this example dimensions distinguish between items (bought) and payment method. Using dimensions has two effects:
- for each dimension the corresponding items are shown in a separate chart with the dimension label for the x axis
- when sorting is applied each dimension is sorted separately
More examples
Complete list of examples:
- Data formatting
- basic data structure
- basic data structure with added colors
- basic data structure with long names
- basic data structure with dimensions
- basic data structure with all column features
- Including data
- standard reference to csv file
- reference to data embedded in html file
- preprocessing csv file before passing it on
- preprocessing embedded data before passing it on
- Visualization options