block by ee2dev 0f7abbfc6ab01513d89a

item explorer - data format - example 2

Full Screen

An example of the required format for item explorer. This example shows how to color code items. Color can be used to denote items belonging together.

More examples

The main example is here.

Complete list of examples:

  1. Data formatting

  2. Including data

  3. Visualization options

index.html

<!DOCTYPE html>	
<meta charset="utf-8">
<head>
  <link rel="stylesheet" type="text/css" href="//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="//www.ankerst.de/lib/itemExplorer_10.min.js"></script>
</head>

<body>
  <script>  
    var myIEChart = itemExplorerChart("items_5c.csv");
    showChart(); 
    
    function showChart() {
      d3.select("body")
        .append("div")
        .attr("class", "chart")
        .call(myIEChart);
    }   
  </script>
</body>
</html> 

items_5c.csv

_customers,B-jui:CO=rgb(128 177 211)B-wat:CO=rgb(128 177 211),B-bee:CO=rgb(128 177 211),B-mil:CO=rgb(128 177 211),B-win:CO=rgb(128 177 211),F-egg:CO=rgb(252 141 98),F-cer:CO=rgb(252 141 98),F-can:CO=rgb(252 141 98),F-mea:CO=rgb(252 141 98),F-fis:CO=rgb(252 141 98),F-fru:CO=rgb(252 141 98),F-veg:CO=rgb(252 141 98),F-che:CO=rgb(252 141 98),O-flo:CO=rgb(127 201 127),O-mag:CO=rgb(127 201 127),O-hyg:CO=rgb(127 201 127),O-cos:CO=rgb(127 201 127)
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