Skip to content

Instantly share code, notes, and snippets.

@EE2dev
Last active November 6, 2015 22:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save EE2dev/d9ad0499316f09c598a3 to your computer and use it in GitHub Desktop.
Save EE2dev/d9ad0499316f09c598a3 to your computer and use it in GitHub Desktop.
item explorer - data format - example 3

An example of the required format for item explorer. Long names can be used to describe items and are shown in the tooltip. Regular item names should not consist of more than 5 letters to allow for a visual appealing label of the x axis. If this means that the item is abbreviated then the long name of the item can be used to reveal the full name.

More examples

The main example is here.

Complete list of examples:

  1. Data formatting
  1. Including data
  1. Visualization options
<!DOCTYPE html>
<meta charset="utf-8">
<head>
<link rel="stylesheet" type="text/css" href="http://www.ankerst.de/lib/itemExplorer_10.css">
<script src="https://cdnjs.cloudflare.com/ajax/libs/d3/3.5.6/d3.min.js"></script>
<script src="http://www.ankerst.de/lib/itemExplorer_10.min.js"></script>
</head>
<body>
<script>
var myIEChart = itemExplorerChart("items_5l.csv");
showChart();
function showChart() {
d3.select("body")
.append("div")
.attr("class", "chart")
.call(myIEChart);
}
</script>
</body>
</html>
_customers B-jui:LN=Beverages - juice B-wat:LN=Beverages - water B-bee:LN=Beverages - beer B-mil:LN=Beverages - milk B-win:LN=Beverages - wine F-egg:LN=Food - eggs F-cer:LN=Food - cereal F-can:LN=Food - candy F-mea:LN=Food - meat F-fis:LN=Food - fish F-fru:LN=Food - fruit F-veg:LN=Food - vegetable F-che:LN=Food - cheese O-flo:LN=Other - flowers O-mag:LN=Other - magazines O-hyg:LN=Other - hygiene O-cos:LN=Other - cosmetics
200000 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1
100000 1 1 1 1 1 1 1 0 0 0 0 0 0 0 0 0 0
100000 0 0 0 0 0 0 0 1 1 1 1 1 1 1 0 0 0
100000 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1
100000 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment