-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathplot_summary.js
More file actions
19 lines (18 loc) · 12.7 KB
/
plot_summary.js
File metadata and controls
19 lines (18 loc) · 12.7 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
Bokeh.$(function() {
var all_models = [{"attributes": {"y": {"field": "y"}, "line_width": {"value": 2}, "id": "955cd844-d0fa-4dc4-a6b4-bb158a96fb1c", "x": {"field": "x"}, "line_alpha": {"value": 0.5}, "tags": [], "line_color": {"value": "red"}, "doc": null}, "type": "Line", "id": "955cd844-d0fa-4dc4-a6b4-bb158a96fb1c"}, {"attributes": {"doc": null, "id": "01739a60-abea-4ac1-b80c-2e176979fcaa", "column_names": ["x", "y"], "selected": {"1d": {"indices": []}, "2d": {"indices": []}, "0d": {"indices": [], "flag": false}}, "tags": [], "callback": null, "data": {"x": ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"], "y": [1.0, 0.09387271895184827, 0.09933092908094897, 0.1034535322505063, 0.12987964122562062, 0.17789949000983807, 0.040523801824564484, 0.2484759899043323, 0.17933957507214127, 0.08788869279738236, 0.04407879772765265, 0.0]}}, "type": "ColumnDataSource", "id": "01739a60-abea-4ac1-b80c-2e176979fcaa"}, {"attributes": {"doc": null, "nonselection_glyph": {"type": "Line", "id": "18a8454c-8ce7-4f34-8630-6f7c7816430c"}, "data_source": {"type": "ColumnDataSource", "id": "f8332994-8a1c-4d94-a144-66105ddf9720"}, "selection_glyph": null, "tags": [], "id": "625f1ea2-b7cb-45a8-8f84-bb8f5515b3b2", "glyph": {"type": "Line", "id": "a7f95ed9-b472-4a56-a6ae-d33326eaef0a"}}, "type": "GlyphRenderer", "id": "625f1ea2-b7cb-45a8-8f84-bb8f5515b3b2"}, {"attributes": {"grid_line_color": {"value": "white"}, "plot": {"subtype": "Figure", "type": "Plot", "id": "5369afb7-4311-42c9-89a9-33c104cb00d6"}, "dimension": 0, "doc": null, "tags": [], "ticker": {"type": "CategoricalTicker", "id": "f02cb12d-043a-4bbb-bd35-cbbce8eb26c7"}, "id": "0924c0f8-67c5-4dca-bae8-5889fa81e7d9"}, "type": "Grid", "id": "0924c0f8-67c5-4dca-bae8-5889fa81e7d9"}, {"attributes": {"plot": {"subtype": "Figure", "type": "Plot", "id": "5369afb7-4311-42c9-89a9-33c104cb00d6"}, "doc": null, "tags": [], "id": "5a018577-4c90-4fc8-a5e4-d5d15b928ccf", "legends": [["start period", [{"type": "GlyphRenderer", "id": "625f1ea2-b7cb-45a8-8f84-bb8f5515b3b2"}]], ["ending period", [{"type": "GlyphRenderer", "id": "5d58fe9b-8113-4fe2-ac26-e6cd19360911"}]]]}, "type": "Legend", "id": "5a018577-4c90-4fc8-a5e4-d5d15b928ccf"}, {"attributes": {"doc": null, "id": "f8332994-8a1c-4d94-a144-66105ddf9720", "column_names": ["y", "x"], "selected": {"1d": {"indices": []}, "2d": {"indices": []}, "0d": {"indices": [], "flag": false}}, "tags": [], "callback": null, "data": {"x": ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"], "y": [1.0, 0.09387271895184827, 0.09933092908094897, 0.1034535322505063, 0.12987964122562062, 0.17789949000983807, 0.040523801824564484, 0.2484759899043323, 0.17933957507214127, 0.08788869279738236, 0.04407879772765265, 0.0]}}, "type": "ColumnDataSource", "id": "f8332994-8a1c-4d94-a144-66105ddf9720"}, {"attributes": {"callback": null, "id": "0f09b63a-ec44-48ff-ad99-3f8dcd5d7cd7", "doc": null, "tags": [], "factors": ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"]}, "type": "FactorRange", "id": "0f09b63a-ec44-48ff-ad99-3f8dcd5d7cd7"}, {"attributes": {"fill_alpha": {"value": 0.1}, "id": "16593b2d-3025-4e20-9153-f6b89074c89c", "fill_color": {"value": "#1f77b4"}, "line_color": {"value": "#1f77b4"}, "tags": [], "size": {"value": 8, "units": "screen"}, "y": {"field": "y"}, "doc": null, "x": {"field": "x"}, "line_alpha": {"value": 0.1}}, "type": "Circle", "id": "16593b2d-3025-4e20-9153-f6b89074c89c"}, {"attributes": {"fill_alpha": {"value": 0.8}, "id": "ba61ea20-042e-4e45-a946-14db82fdedaa", "fill_color": {"value": "white"}, "line_color": {"value": "green"}, "tags": [], "size": {"value": 8, "units": "screen"}, "y": {"field": "y"}, "doc": null, "x": {"field": "x"}, "line_alpha": {"value": 0.8}}, "type": "Circle", "id": "ba61ea20-042e-4e45-a946-14db82fdedaa"}, {"attributes": {"mantissas": [2, 5, 10], "id": "a535cc95-a755-4449-9983-d7fe839fa681", "doc": null, "num_minor_ticks": 5, "tags": []}, "type": "BasicTicker", "id": "a535cc95-a755-4449-9983-d7fe839fa681"}, {"attributes": {"id": "f02cb12d-043a-4bbb-bd35-cbbce8eb26c7", "doc": null, "num_minor_ticks": 5, "tags": []}, "type": "CategoricalTicker", "id": "f02cb12d-043a-4bbb-bd35-cbbce8eb26c7"}, {"attributes": {"id": "adafb842-c0c5-4786-98ea-2ad6ab815728", "doc": null, "tags": [], "callback": null, "renderers": [], "names": []}, "type": "DataRange1d", "id": "adafb842-c0c5-4786-98ea-2ad6ab815728"}, {"attributes": {"formatter": {"type": "CategoricalTickFormatter", "id": "6177a71a-1183-4bf1-8520-43f771c9f18d"}, "plot": {"subtype": "Figure", "type": "Plot", "id": "5369afb7-4311-42c9-89a9-33c104cb00d6"}, "doc": null, "tags": [], "ticker": {"type": "CategoricalTicker", "id": "f02cb12d-043a-4bbb-bd35-cbbce8eb26c7"}, "id": "229162c5-4e20-4811-bc8c-65ae0869676f", "axis_label": "Month"}, "type": "CategoricalAxis", "id": "229162c5-4e20-4811-bc8c-65ae0869676f"}, {"attributes": {"geometries": [], "id": "3b30c05f-eea6-46df-a654-9abadc7f9003", "doc": null, "tags": []}, "type": "ToolEvents", "id": "3b30c05f-eea6-46df-a654-9abadc7f9003"}, {"attributes": {"fill_alpha": {"value": 0.8}, "id": "e1443802-e2e2-4727-b8f0-a45f38ef9236", "fill_color": {"value": "white"}, "line_color": {"value": "red"}, "tags": [], "size": {"value": 8, "units": "screen"}, "y": {"field": "y"}, "doc": null, "x": {"field": "x"}, "line_alpha": {"value": 0.8}}, "type": "Circle", "id": "e1443802-e2e2-4727-b8f0-a45f38ef9236"}, {"attributes": {"title": "Reported Job starting and ending points", "below": [{"type": "CategoricalAxis", "id": "229162c5-4e20-4811-bc8c-65ae0869676f"}], "y_range": {"type": "DataRange1d", "id": "adafb842-c0c5-4786-98ea-2ad6ab815728"}, "right": [], "id": "5369afb7-4311-42c9-89a9-33c104cb00d6", "extra_y_ranges": {}, "plot_width": 750, "tags": [], "tool_events": {"type": "ToolEvents", "id": "3b30c05f-eea6-46df-a654-9abadc7f9003"}, "x_range": {"type": "FactorRange", "id": "0f09b63a-ec44-48ff-ad99-3f8dcd5d7cd7"}, "above": [], "renderers": [{"type": "CategoricalAxis", "id": "229162c5-4e20-4811-bc8c-65ae0869676f"}, {"type": "Grid", "id": "0924c0f8-67c5-4dca-bae8-5889fa81e7d9"}, {"type": "LinearAxis", "id": "d7c5f9ca-50c0-4837-8eb4-b29e1dad62cb"}, {"type": "Grid", "id": "bc105b76-ef7d-4c89-87fe-e185a3d0c7f4"}, {"type": "Legend", "id": "5a018577-4c90-4fc8-a5e4-d5d15b928ccf"}, {"type": "GlyphRenderer", "id": "625f1ea2-b7cb-45a8-8f84-bb8f5515b3b2"}, {"type": "GlyphRenderer", "id": "5d58fe9b-8113-4fe2-ac26-e6cd19360911"}, {"type": "GlyphRenderer", "id": "9ecd50c8-a534-4f2d-8165-9b5e590fcbdb"}, {"type": "GlyphRenderer", "id": "bca90439-c46d-446a-a50f-47c0cd1a3599"}], "tools": [{"type": "HoverTool", "id": "0f7901c8-b092-4222-b07f-1dac28e66aaa"}], "doc": null, "left": [{"type": "LinearAxis", "id": "d7c5f9ca-50c0-4837-8eb4-b29e1dad62cb"}], "background_fill": "#cccccc", "extra_x_ranges": {}, "plot_height": 350}, "subtype": "Figure", "type": "Plot", "id": "5369afb7-4311-42c9-89a9-33c104cb00d6"}, {"attributes": {"doc": null, "nonselection_glyph": {"type": "Circle", "id": "16593b2d-3025-4e20-9153-f6b89074c89c"}, "data_source": {"type": "ColumnDataSource", "id": "01739a60-abea-4ac1-b80c-2e176979fcaa"}, "selection_glyph": null, "tags": [], "id": "9ecd50c8-a534-4f2d-8165-9b5e590fcbdb", "glyph": {"type": "Circle", "id": "ba61ea20-042e-4e45-a946-14db82fdedaa"}}, "type": "GlyphRenderer", "id": "9ecd50c8-a534-4f2d-8165-9b5e590fcbdb"}, {"attributes": {"doc": null, "tags": [], "id": "7fde5962-565b-42d7-890e-ddd53e4db1a2"}, "type": "BasicTickFormatter", "id": "7fde5962-565b-42d7-890e-ddd53e4db1a2"}, {"attributes": {"fill_alpha": {"value": 0.1}, "id": "1ce28f92-4106-4d3a-b464-31a73da6a5fd", "fill_color": {"value": "#1f77b4"}, "line_color": {"value": "#1f77b4"}, "tags": [], "size": {"value": 8, "units": "screen"}, "y": {"field": "y"}, "doc": null, "x": {"field": "x"}, "line_alpha": {"value": 0.1}}, "type": "Circle", "id": "1ce28f92-4106-4d3a-b464-31a73da6a5fd"}, {"attributes": {"y": {"field": "y"}, "line_width": {"value": 2}, "id": "18a8454c-8ce7-4f34-8630-6f7c7816430c", "x": {"field": "x"}, "line_alpha": {"value": 0.1}, "tags": [], "line_color": {"value": "#1f77b4"}, "doc": null}, "type": "Line", "id": "18a8454c-8ce7-4f34-8630-6f7c7816430c"}, {"attributes": {"tooltips": [["value: ", "@y"]], "tags": [], "id": "0f7901c8-b092-4222-b07f-1dac28e66aaa", "plot": {"subtype": "Figure", "type": "Plot", "id": "5369afb7-4311-42c9-89a9-33c104cb00d6"}, "doc": null, "names": [], "callback": null, "renderers": [], "always_active": true}, "type": "HoverTool", "id": "0f7901c8-b092-4222-b07f-1dac28e66aaa"}, {"attributes": {"y": {"field": "y"}, "line_width": {"value": 2}, "id": "a7f95ed9-b472-4a56-a6ae-d33326eaef0a", "x": {"field": "x"}, "line_alpha": {"value": 0.5}, "tags": [], "line_color": {"value": "green"}, "doc": null}, "type": "Line", "id": "a7f95ed9-b472-4a56-a6ae-d33326eaef0a"}, {"attributes": {"doc": null, "tags": [], "id": "6177a71a-1183-4bf1-8520-43f771c9f18d"}, "type": "CategoricalTickFormatter", "id": "6177a71a-1183-4bf1-8520-43f771c9f18d"}, {"attributes": {"grid_line_color": {"value": "white"}, "plot": {"subtype": "Figure", "type": "Plot", "id": "5369afb7-4311-42c9-89a9-33c104cb00d6"}, "dimension": 1, "doc": null, "tags": [], "ticker": {"type": "BasicTicker", "id": "a535cc95-a755-4449-9983-d7fe839fa681"}, "id": "bc105b76-ef7d-4c89-87fe-e185a3d0c7f4"}, "type": "Grid", "id": "bc105b76-ef7d-4c89-87fe-e185a3d0c7f4"}, {"attributes": {"formatter": {"type": "BasicTickFormatter", "id": "7fde5962-565b-42d7-890e-ddd53e4db1a2"}, "plot": {"subtype": "Figure", "type": "Plot", "id": "5369afb7-4311-42c9-89a9-33c104cb00d6"}, "doc": null, "tags": [], "ticker": {"type": "BasicTicker", "id": "a535cc95-a755-4449-9983-d7fe839fa681"}, "id": "d7c5f9ca-50c0-4837-8eb4-b29e1dad62cb", "axis_label": "Normalized Value"}, "type": "LinearAxis", "id": "d7c5f9ca-50c0-4837-8eb4-b29e1dad62cb"}, {"attributes": {"doc": null, "nonselection_glyph": {"type": "Circle", "id": "1ce28f92-4106-4d3a-b464-31a73da6a5fd"}, "data_source": {"type": "ColumnDataSource", "id": "43e838e7-d390-4016-b83c-72f44991bd58"}, "selection_glyph": null, "tags": [], "id": "bca90439-c46d-446a-a50f-47c0cd1a3599", "glyph": {"type": "Circle", "id": "e1443802-e2e2-4727-b8f0-a45f38ef9236"}}, "type": "GlyphRenderer", "id": "bca90439-c46d-446a-a50f-47c0cd1a3599"}, {"attributes": {"doc": null, "id": "43e838e7-d390-4016-b83c-72f44991bd58", "column_names": ["x", "y"], "selected": {"1d": {"indices": []}, "2d": {"indices": []}, "0d": {"indices": [], "flag": false}}, "tags": [], "callback": null, "data": {"x": ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"], "y": [1.0, 0.1192316177629298, 0.1480427999621797, 0.1574695073907151, 0.16319140218727346, 0.17758832613697248, 0.03562198619559394, 0.3238409656780863, 0.24196003655961426, 0.1154637713133096, 0.06129881181253743, 0.0]}}, "type": "ColumnDataSource", "id": "43e838e7-d390-4016-b83c-72f44991bd58"}, {"attributes": {"y": {"field": "y"}, "line_width": {"value": 2}, "id": "3ec692e3-4aef-4096-af58-6130ee551d0b", "x": {"field": "x"}, "line_alpha": {"value": 0.1}, "tags": [], "line_color": {"value": "#1f77b4"}, "doc": null}, "type": "Line", "id": "3ec692e3-4aef-4096-af58-6130ee551d0b"}, {"attributes": {"doc": null, "nonselection_glyph": {"type": "Line", "id": "3ec692e3-4aef-4096-af58-6130ee551d0b"}, "data_source": {"type": "ColumnDataSource", "id": "84eb656a-5a61-4727-969a-9012d3f445f8"}, "selection_glyph": null, "tags": [], "id": "5d58fe9b-8113-4fe2-ac26-e6cd19360911", "glyph": {"type": "Line", "id": "955cd844-d0fa-4dc4-a6b4-bb158a96fb1c"}}, "type": "GlyphRenderer", "id": "5d58fe9b-8113-4fe2-ac26-e6cd19360911"}, {"attributes": {"doc": null, "id": "84eb656a-5a61-4727-969a-9012d3f445f8", "column_names": ["x", "y"], "selected": {"1d": {"indices": []}, "2d": {"indices": []}, "0d": {"indices": [], "flag": false}}, "tags": [], "callback": null, "data": {"x": ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"], "y": [1.0, 0.1192316177629298, 0.1480427999621797, 0.1574695073907151, 0.16319140218727346, 0.17758832613697248, 0.03562198619559394, 0.3238409656780863, 0.24196003655961426, 0.1154637713133096, 0.06129881181253743, 0.0]}}, "type": "ColumnDataSource", "id": "84eb656a-5a61-4727-969a-9012d3f445f8"}];
Bokeh.load_models(all_models);
var plots = [{'modelid': '5369afb7-4311-42c9-89a9-33c104cb00d6', 'modeltype': 'Plot', 'elementid': '0afee618-adfb-4d31-bd35-aaca87475ba6'}];
for (idx in plots) {
var plot = plots[idx];
var model = Bokeh.Collections(plot.modeltype).get(plot.modelid);
Bokeh.logger.info('Realizing plot:')
Bokeh.logger.info(' - modeltype: ' + plot.modeltype);
Bokeh.logger.info(' - modelid: ' + plot.modelid);
Bokeh.logger.info(' - elementid: ' + plot.elementid);
var view = new model.default_view({
model: model,
el: '#' + plot.elementid
});
Bokeh.index[plot.modelid] = view;
}
});