-
Notifications
You must be signed in to change notification settings - Fork 0
/
stacked.html
85 lines (51 loc) · 8.87 KB
/
stacked.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Bokeh Plot</title>
<link rel="stylesheet" href="https://cdn.pydata.org/bokeh/release/bokeh-1.0.1.min.css" type="text/css" />
<script type="text/javascript" src="https://cdn.pydata.org/bokeh/release/bokeh-1.0.1.min.js"></script>
<script type="text/javascript">
Bokeh.set_log_level("info");
</script>
</head>
<body>
<div class="bk-root" id="7574934a-945d-4080-9861-86fd9d335c02"></div>
<script type="application/json" id="2341">
{"9f85ecbe-faad-4ea2-bdfc-dfe6d0c256bf":{"roots":{"references":[{"attributes":{"source":{"id":"2232","type":"ColumnDataSource"}},"id":"2237","type":"CDSView"},{"attributes":{"formatter":{"id":"2241","type":"BasicTickFormatter"},"minor_tick_line_color":{"value":null},"plot":{"id":"2194","subtype":"Figure","type":"Plot"},"ticker":{"id":"2209","type":"BasicTicker"}},"id":"2208","type":"LinearAxis"},{"attributes":{},"id":"2258","type":"Selection"},{"attributes":{"fields":[]},"id":"2228","type":"Stack"},{"attributes":{"bottom_units":"screen","fill_alpha":{"value":0.5},"fill_color":{"value":"lightgrey"},"left_units":"screen","level":"overlay","line_alpha":{"value":1.0},"line_color":{"value":"black"},"line_dash":[4,4],"line_width":{"value":2},"plot":null,"render_mode":"css","right_units":"screen","top_units":"screen"},"id":"2221","type":"BoxAnnotation"},{"attributes":{"bottom":{"expr":{"id":"2230","type":"Stack"}},"fill_alpha":{"value":0.1},"fill_color":{"value":"#1f77b4"},"line_alpha":{"value":0.1},"line_color":{"value":"#1f77b4"},"top":{"expr":{"id":"2231","type":"Stack"}},"width":{"value":0.9},"x":{"field":"stay"}},"id":"2249","type":"VBar"},{"attributes":{},"id":"2239","type":"CategoricalTickFormatter"},{"attributes":{},"id":"2202","type":"LinearScale"},{"attributes":{},"id":"2209","type":"BasicTicker"},{"attributes":{"plot":null,"text":"Number of Users married and years in city"},"id":"2193","type":"Title"},{"attributes":{},"id":"2241","type":"BasicTickFormatter"},{"attributes":{"fields":["No","Yes"]},"id":"2231","type":"Stack"},{"attributes":{"fields":["No"]},"id":"2230","type":"Stack"},{"attributes":{"grid_line_color":{"value":null},"plot":{"id":"2194","subtype":"Figure","type":"Plot"},"ticker":{"id":"2205","type":"CategoricalTicker"}},"id":"2207","type":"Grid"},{"attributes":{"bottom":{"expr":{"id":"2228","type":"Stack"}},"fill_alpha":{"value":0.1},"fill_color":{"value":"#1f77b4"},"line_alpha":{"value":0.1},"line_color":{"value":"#1f77b4"},"top":{"expr":{"id":"2229","type":"Stack"}},"width":{"value":0.9},"x":{"field":"stay"}},"id":"2235","type":"VBar"},{"attributes":{},"id":"2200","type":"CategoricalScale"},{"attributes":{"callback":null,"data":{"No":[305,918,482,400,369],"Yes":[467,1168,663,579,540],"stay":["0","1","2","3","4+"]},"selected":{"id":"2269","type":"Selection"},"selection_policy":{"id":"2268","type":"UnionRenderers"}},"id":"2246","type":"ColumnDataSource"},{"attributes":{},"id":"2214","type":"WheelZoomTool"},{"attributes":{"callback":null,"data":{"No":[305,918,482,400,369],"Yes":[467,1168,663,579,540],"stay":["0","1","2","3","4+"]},"selected":{"id":"2258","type":"Selection"},"selection_policy":{"id":"2257","type":"UnionRenderers"}},"id":"2232","type":"ColumnDataSource"},{"attributes":{},"id":"2269","type":"Selection"},{"attributes":{},"id":"2218","type":"HelpTool"},{"attributes":{"data_source":{"id":"2246","type":"ColumnDataSource"},"glyph":{"id":"2248","type":"VBar"},"hover_glyph":null,"muted_glyph":null,"name":"Yes","nonselection_glyph":{"id":"2249","type":"VBar"},"selection_glyph":null,"view":{"id":"2251","type":"CDSView"}},"id":"2250","type":"GlyphRenderer"},{"attributes":{"label":{"value":"Yes"},"renderers":[{"id":"2250","type":"GlyphRenderer"}]},"id":"2260","type":"LegendItem"},{"attributes":{},"id":"2268","type":"UnionRenderers"},{"attributes":{"callback":null,"start":0},"id":"2198","type":"DataRange1d"},{"attributes":{"source":{"id":"2246","type":"ColumnDataSource"}},"id":"2251","type":"CDSView"},{"attributes":{"overlay":{"id":"2221","type":"BoxAnnotation"}},"id":"2215","type":"BoxZoomTool"},{"attributes":{"bottom":{"expr":{"id":"2230","type":"Stack"}},"fill_color":{"value":"#718dbf"},"line_color":{"value":"#718dbf"},"top":{"expr":{"id":"2231","type":"Stack"}},"width":{"value":0.9},"x":{"field":"stay"}},"id":"2248","type":"VBar"},{"attributes":{},"id":"2216","type":"SaveTool"},{"attributes":{},"id":"2205","type":"CategoricalTicker"},{"attributes":{"below":[{"id":"2204","type":"CategoricalAxis"}],"left":[{"id":"2208","type":"LinearAxis"}],"outline_line_color":{"value":null},"renderers":[{"id":"2204","type":"CategoricalAxis"},{"id":"2207","type":"Grid"},{"id":"2208","type":"LinearAxis"},{"id":"2212","type":"Grid"},{"id":"2221","type":"BoxAnnotation"},{"id":"2244","type":"Legend"},{"id":"2236","type":"GlyphRenderer"},{"id":"2250","type":"GlyphRenderer"}],"title":{"id":"2193","type":"Title"},"toolbar":{"id":"2219","type":"Toolbar"},"x_range":{"id":"2196","type":"FactorRange"},"x_scale":{"id":"2200","type":"CategoricalScale"},"y_range":{"id":"2198","type":"DataRange1d"},"y_scale":{"id":"2202","type":"LinearScale"}},"id":"2194","subtype":"Figure","type":"Plot"},{"attributes":{"data_source":{"id":"2232","type":"ColumnDataSource"},"glyph":{"id":"2234","type":"VBar"},"hover_glyph":null,"muted_glyph":null,"name":"No","nonselection_glyph":{"id":"2235","type":"VBar"},"selection_glyph":null,"view":{"id":"2237","type":"CDSView"}},"id":"2236","type":"GlyphRenderer"},{"attributes":{},"id":"2217","type":"ResetTool"},{"attributes":{"dimension":1,"plot":{"id":"2194","subtype":"Figure","type":"Plot"},"ticker":{"id":"2209","type":"BasicTicker"}},"id":"2212","type":"Grid"},{"attributes":{"items":[{"id":"2245","type":"LegendItem"},{"id":"2260","type":"LegendItem"}],"location":"top_left","orientation":"horizontal","plot":{"id":"2194","subtype":"Figure","type":"Plot"}},"id":"2244","type":"Legend"},{"attributes":{"callback":null,"factors":["0","1","2","3","4+"],"range_padding":0.1},"id":"2196","type":"FactorRange"},{"attributes":{"fields":["No"]},"id":"2229","type":"Stack"},{"attributes":{"formatter":{"id":"2239","type":"CategoricalTickFormatter"},"minor_tick_line_color":{"value":null},"plot":{"id":"2194","subtype":"Figure","type":"Plot"},"ticker":{"id":"2205","type":"CategoricalTicker"}},"id":"2204","type":"CategoricalAxis"},{"attributes":{"active_drag":"auto","active_inspect":"auto","active_multi":null,"active_scroll":"auto","active_tap":"auto","tools":[{"id":"2213","type":"PanTool"},{"id":"2214","type":"WheelZoomTool"},{"id":"2215","type":"BoxZoomTool"},{"id":"2216","type":"SaveTool"},{"id":"2217","type":"ResetTool"},{"id":"2218","type":"HelpTool"}]},"id":"2219","type":"Toolbar"},{"attributes":{"label":{"value":"No"},"renderers":[{"id":"2236","type":"GlyphRenderer"}]},"id":"2245","type":"LegendItem"},{"attributes":{},"id":"2213","type":"PanTool"},{"attributes":{"bottom":{"expr":{"id":"2228","type":"Stack"}},"fill_color":{"value":"#c9d9d3"},"line_color":{"value":"#c9d9d3"},"top":{"expr":{"id":"2229","type":"Stack"}},"width":{"value":0.9},"x":{"field":"stay"}},"id":"2234","type":"VBar"},{"attributes":{},"id":"2257","type":"UnionRenderers"}],"root_ids":["2194"]},"title":"Bokeh Application","version":"1.0.1"}}
</script>
<script type="text/javascript">
(function() {
var fn = function() {
Bokeh.safely(function() {
(function(root) {
function embed_document(root) {
var docs_json = document.getElementById('2341').textContent;
var render_items = [{"docid":"9f85ecbe-faad-4ea2-bdfc-dfe6d0c256bf","roots":{"2194":"7574934a-945d-4080-9861-86fd9d335c02"}}];
root.Bokeh.embed.embed_items(docs_json, render_items);
}
if (root.Bokeh !== undefined) {
embed_document(root);
} else {
var attempts = 0;
var timer = setInterval(function(root) {
if (root.Bokeh !== undefined) {
embed_document(root);
clearInterval(timer);
}
attempts++;
if (attempts > 100) {
console.log("Bokeh: ERROR: Unable to run BokehJS code because BokehJS library is missing");
clearInterval(timer);
}
}, 10, root)
}
})(window);
});
};
if (document.readyState != "loading") fn();
else document.addEventListener("DOMContentLoaded", fn);
})();
</script>
</body>
</html>