(function() {
  var fn = function() {
    
    (function(root) {
      function now() {
        return new Date();
      }
    
      var force = false;
    
      if (typeof (root._bokeh_onload_callbacks) === "undefined" || force === true) {
        root._bokeh_onload_callbacks = [];
        root._bokeh_is_loading = undefined;
      }
    
      
      
    
      
      
    
      function run_callbacks() {
        try {
          root._bokeh_onload_callbacks.forEach(function(callback) { callback() });
        }
        finally {
          delete root._bokeh_onload_callbacks
        }
        console.info("Bokeh: all callbacks have finished");
      }
    
      function load_libs(js_urls, callback) {
        root._bokeh_onload_callbacks.push(callback);
        if (root._bokeh_is_loading > 0) {
          console.log("Bokeh: BokehJS is being loaded, scheduling callback at", now());
          return null;
        }
        if (js_urls == null || js_urls.length === 0) {
          run_callbacks();
          return null;
        }
        console.log("Bokeh: BokehJS not loaded, scheduling load and callback at", now());
        root._bokeh_is_loading = js_urls.length;
        for (var i = 0; i < js_urls.length; i++) {
          var url = js_urls[i];
          var s = document.createElement('script');
          s.src = url;
          s.async = false;
          s.onreadystatechange = s.onload = function() {
            root._bokeh_is_loading--;
            if (root._bokeh_is_loading === 0) {
              console.log("Bokeh: all BokehJS libraries loaded");
              run_callbacks()
            }
          };
          s.onerror = function() {
            console.warn("failed to load library " + url);
          };
          console.log("Bokeh: injecting script tag for BokehJS library: ", url);
          document.getElementsByTagName("head")[0].appendChild(s);
        }
      };var element = document.getElementById("b5127d25-f109-4710-a3c2-0a4b1c6c31ae");
      if (element == null) {
        console.log("Bokeh: ERROR: autoload.js configured with elementid 'b5127d25-f109-4710-a3c2-0a4b1c6c31ae' but no matching script tag was found. ")
        return false;
      }
    
      var js_urls = ["https://cdn.pydata.org/bokeh/release/bokeh-0.12.9.min.js", "https://cdn.pydata.org/bokeh/release/bokeh-widgets-0.12.9.min.js", "https://cdn.pydata.org/bokeh/release/bokeh-tables-0.12.9.min.js", "https://cdn.pydata.org/bokeh/release/bokeh-gl-0.12.9.min.js"];
    
      var inline_js = [
        function(Bokeh) {
          Bokeh.set_log_level("info");
        },
        
        function(Bokeh) {
          
        },
        
        function(Bokeh) {
          (function() {
            var fn = function() {
              Bokeh.safely(function() {
                (function(root) {
                  function embed_document(root) {
                    var docs_json = {"b964cc4d-9e89-4154-9cf7-5d268596bd17":{"roots":{"references":[{"attributes":{},"id":"645a5d74-b84d-4eb1-88bf-eca6b6ec6881","type":"CategoricalScale"},{"attributes":{"bottom":{"expr":{"id":"73799232-26d9-45a7-9224-a8363c0b75fa","type":"Stack"}},"fill_color":{"value":"#c9d9d3"},"line_color":{"value":"#c9d9d3"},"top":{"expr":{"id":"096e685a-14e5-4fbb-8a8b-fc68411e2a91","type":"Stack"}},"width":{"value":0.9},"x":{"field":"fruits"}},"id":"2e79e7b5-21f0-4e34-8a9c-2e6253eb02cb","type":"VBar"},{"attributes":{"fields":["2015","2016"]},"id":"a356c7dc-9bb7-480b-82ce-25dbb9d49efa","type":"Stack"},{"attributes":{"below":[{"id":"2403a3d5-5411-4214-8886-0e0e64e3e963","type":"CategoricalAxis"}],"left":[{"id":"d61e51b2-1b0e-4013-a02c-b90d4c259c07","type":"LinearAxis"}],"outline_line_color":{"value":null},"plot_height":350,"renderers":[{"id":"2403a3d5-5411-4214-8886-0e0e64e3e963","type":"CategoricalAxis"},{"id":"e301e640-e2d2-4cef-849a-8e8788cd1278","type":"Grid"},{"id":"d61e51b2-1b0e-4013-a02c-b90d4c259c07","type":"LinearAxis"},{"id":"1fa61d98-c9fc-4c9b-8f04-2f9fff4a6f5c","type":"Grid"},{"id":"f46c6b16-a25e-4637-86a5-6818ade7d052","type":"Legend"},{"id":"a9e7876a-3363-4915-8ce4-3ea1952e5b62","type":"GlyphRenderer"},{"id":"c1979f5d-151a-4052-bd04-fcb106fe9a0c","type":"GlyphRenderer"},{"id":"3d9d3650-8dbd-416b-b53b-5a6fd0068690","type":"GlyphRenderer"}],"title":{"id":"88286aa0-1b07-47b8-a8c3-6dc98c321008","type":"Title"},"toolbar":{"id":"33f6f596-6834-4195-b56d-0116c832205e","type":"Toolbar"},"toolbar_location":null,"x_range":{"id":"859ed9a0-89be-4c55-9cac-6e40776b3be1","type":"FactorRange"},"x_scale":{"id":"645a5d74-b84d-4eb1-88bf-eca6b6ec6881","type":"CategoricalScale"},"y_range":{"id":"44975ccb-95aa-4f35-8963-6886c09c3434","type":"DataRange1d"},"y_scale":{"id":"446d68ae-0473-43a2-8ee6-026040c61d80","type":"LinearScale"}},"id":"4181283a-62fa-42cf-a296-42bc2136d908","subtype":"Figure","type":"Plot"},{"attributes":{"data_source":{"id":"efc4fe2b-7528-4531-98d3-cbbf5dd13102","type":"ColumnDataSource"},"glyph":{"id":"2e79e7b5-21f0-4e34-8a9c-2e6253eb02cb","type":"VBar"},"hover_glyph":null,"muted_glyph":null,"nonselection_glyph":{"id":"940f6f3e-7d57-4499-8ed8-bc1472931626","type":"VBar"},"selection_glyph":null,"view":{"id":"2719f2fd-28ba-46ed-bb11-f0ae16d159c1","type":"CDSView"}},"id":"a9e7876a-3363-4915-8ce4-3ea1952e5b62","type":"GlyphRenderer"},{"attributes":{},"id":"82276fd0-5cd3-4654-9293-2c74b5e1a3ba","type":"CategoricalTickFormatter"},{"attributes":{"source":{"id":"efc4fe2b-7528-4531-98d3-cbbf5dd13102","type":"ColumnDataSource"}},"id":"21a469a3-ea2c-4c7c-a62b-6fbfd8df5a98","type":"CDSView"},{"attributes":{"callback":null,"start":0},"id":"44975ccb-95aa-4f35-8963-6886c09c3434","type":"DataRange1d"},{"attributes":{"source":{"id":"efc4fe2b-7528-4531-98d3-cbbf5dd13102","type":"ColumnDataSource"}},"id":"fb899f62-5d8e-4e8d-ae50-878b4ca427de","type":"CDSView"},{"attributes":{"callback":null,"factors":["Apples","Pears","Nectarines","Plums","Grapes","Strawberries"],"range_padding":0.1},"id":"859ed9a0-89be-4c55-9cac-6e40776b3be1","type":"FactorRange"},{"attributes":{"data_source":{"id":"efc4fe2b-7528-4531-98d3-cbbf5dd13102","type":"ColumnDataSource"},"glyph":{"id":"a5c3e0b3-5272-46cf-9eae-e053c80a63a9","type":"VBar"},"hover_glyph":null,"muted_glyph":null,"nonselection_glyph":{"id":"83cbfa21-03e6-43ae-8d51-048a0a6240bb","type":"VBar"},"selection_glyph":null,"view":{"id":"fb899f62-5d8e-4e8d-ae50-878b4ca427de","type":"CDSView"}},"id":"c1979f5d-151a-4052-bd04-fcb106fe9a0c","type":"GlyphRenderer"},{"attributes":{"bottom":{"expr":{"id":"c71d10db-453f-4362-93a0-5108c23a9094","type":"Stack"}},"fill_color":{"value":"#718dbf"},"line_color":{"value":"#718dbf"},"top":{"expr":{"id":"3970a7ee-4902-420b-a338-c51339f307a6","type":"Stack"}},"width":{"value":0.9},"x":{"field":"fruits"}},"id":"a5c3e0b3-5272-46cf-9eae-e053c80a63a9","type":"VBar"},{"attributes":{"bottom":{"expr":{"id":"c71d10db-453f-4362-93a0-5108c23a9094","type":"Stack"}},"fill_alpha":{"value":0.1},"fill_color":{"value":"#1f77b4"},"line_alpha":{"value":0.1},"line_color":{"value":"#1f77b4"},"top":{"expr":{"id":"3970a7ee-4902-420b-a338-c51339f307a6","type":"Stack"}},"width":{"value":0.9},"x":{"field":"fruits"}},"id":"83cbfa21-03e6-43ae-8d51-048a0a6240bb","type":"VBar"},{"attributes":{},"id":"e9afad1b-6392-4857-86c0-7312f49a1d33","type":"CategoricalTicker"},{"attributes":{"fields":["2015","2016"]},"id":"3970a7ee-4902-420b-a338-c51339f307a6","type":"Stack"},{"attributes":{"plot":null,"text":"Fruit Counts by Year"},"id":"88286aa0-1b07-47b8-a8c3-6dc98c321008","type":"Title"},{"attributes":{},"id":"4d5262a2-9529-4d23-a543-7fb33528baea","type":"BasicTickFormatter"},{"attributes":{"bottom":{"expr":{"id":"73799232-26d9-45a7-9224-a8363c0b75fa","type":"Stack"}},"fill_alpha":{"value":0.1},"fill_color":{"value":"#1f77b4"},"line_alpha":{"value":0.1},"line_color":{"value":"#1f77b4"},"top":{"expr":{"id":"096e685a-14e5-4fbb-8a8b-fc68411e2a91","type":"Stack"}},"width":{"value":0.9},"x":{"field":"fruits"}},"id":"940f6f3e-7d57-4499-8ed8-bc1472931626","type":"VBar"},{"attributes":{"bottom":{"expr":{"id":"a356c7dc-9bb7-480b-82ce-25dbb9d49efa","type":"Stack"}},"fill_color":{"value":"#e84d60"},"line_color":{"value":"#e84d60"},"top":{"expr":{"id":"2f2c3987-face-4ad8-8476-b0471f9a3de2","type":"Stack"}},"width":{"value":0.9},"x":{"field":"fruits"}},"id":"02785144-6aeb-4d23-af9c-db023df6c4cd","type":"VBar"},{"attributes":{"label":{"value":"2016"},"renderers":[{"id":"c1979f5d-151a-4052-bd04-fcb106fe9a0c","type":"GlyphRenderer"}]},"id":"40cbc900-2b23-4f2b-aecb-ad72fdf240da","type":"LegendItem"},{"attributes":{"label":{"value":"2015"},"renderers":[{"id":"a9e7876a-3363-4915-8ce4-3ea1952e5b62","type":"GlyphRenderer"}]},"id":"40d9bbe6-0532-4248-ad48-0465ff9245e3","type":"LegendItem"},{"attributes":{"data_source":{"id":"efc4fe2b-7528-4531-98d3-cbbf5dd13102","type":"ColumnDataSource"},"glyph":{"id":"02785144-6aeb-4d23-af9c-db023df6c4cd","type":"VBar"},"hover_glyph":null,"muted_glyph":null,"nonselection_glyph":{"id":"426055de-255e-4b47-a363-dc36c25ad1b1","type":"VBar"},"selection_glyph":null,"view":{"id":"21a469a3-ea2c-4c7c-a62b-6fbfd8df5a98","type":"CDSView"}},"id":"3d9d3650-8dbd-416b-b53b-5a6fd0068690","type":"GlyphRenderer"},{"attributes":{"active_drag":"auto","active_inspect":"auto","active_scroll":"auto","active_tap":"auto"},"id":"33f6f596-6834-4195-b56d-0116c832205e","type":"Toolbar"},{"attributes":{},"id":"446d68ae-0473-43a2-8ee6-026040c61d80","type":"LinearScale"},{"attributes":{"label":{"value":"2017"},"renderers":[{"id":"3d9d3650-8dbd-416b-b53b-5a6fd0068690","type":"GlyphRenderer"}]},"id":"aed82689-cddb-4c45-b98b-d90b8d83506a","type":"LegendItem"},{"attributes":{"fields":["2015","2016","2017"]},"id":"2f2c3987-face-4ad8-8476-b0471f9a3de2","type":"Stack"},{"attributes":{"grid_line_color":{"value":null},"plot":{"id":"4181283a-62fa-42cf-a296-42bc2136d908","subtype":"Figure","type":"Plot"},"ticker":{"id":"e9afad1b-6392-4857-86c0-7312f49a1d33","type":"CategoricalTicker"}},"id":"e301e640-e2d2-4cef-849a-8e8788cd1278","type":"Grid"},{"attributes":{"fields":["2015"]},"id":"096e685a-14e5-4fbb-8a8b-fc68411e2a91","type":"Stack"},{"attributes":{},"id":"369a3910-2f6e-4e92-bd69-c40e091c04ab","type":"BasicTicker"},{"attributes":{"bottom":{"expr":{"id":"a356c7dc-9bb7-480b-82ce-25dbb9d49efa","type":"Stack"}},"fill_alpha":{"value":0.1},"fill_color":{"value":"#1f77b4"},"line_alpha":{"value":0.1},"line_color":{"value":"#1f77b4"},"top":{"expr":{"id":"2f2c3987-face-4ad8-8476-b0471f9a3de2","type":"Stack"}},"width":{"value":0.9},"x":{"field":"fruits"}},"id":"426055de-255e-4b47-a363-dc36c25ad1b1","type":"VBar"},{"attributes":{"callback":null,"column_names":["2015","2017","2016","fruits"],"data":{"2015":[2,1,4,3,2,4],"2016":[5,3,4,2,4,6],"2017":[3,2,4,4,5,3],"fruits":["Apples","Pears","Nectarines","Plums","Grapes","Strawberries"]}},"id":"efc4fe2b-7528-4531-98d3-cbbf5dd13102","type":"ColumnDataSource"},{"attributes":{"fields":["2015"]},"id":"c71d10db-453f-4362-93a0-5108c23a9094","type":"Stack"},{"attributes":{"source":{"id":"efc4fe2b-7528-4531-98d3-cbbf5dd13102","type":"ColumnDataSource"}},"id":"2719f2fd-28ba-46ed-bb11-f0ae16d159c1","type":"CDSView"},{"attributes":{"fields":[]},"id":"73799232-26d9-45a7-9224-a8363c0b75fa","type":"Stack"},{"attributes":{"formatter":{"id":"4d5262a2-9529-4d23-a543-7fb33528baea","type":"BasicTickFormatter"},"minor_tick_line_color":{"value":null},"plot":{"id":"4181283a-62fa-42cf-a296-42bc2136d908","subtype":"Figure","type":"Plot"},"ticker":{"id":"369a3910-2f6e-4e92-bd69-c40e091c04ab","type":"BasicTicker"}},"id":"d61e51b2-1b0e-4013-a02c-b90d4c259c07","type":"LinearAxis"},{"attributes":{"formatter":{"id":"82276fd0-5cd3-4654-9293-2c74b5e1a3ba","type":"CategoricalTickFormatter"},"minor_tick_line_color":{"value":null},"plot":{"id":"4181283a-62fa-42cf-a296-42bc2136d908","subtype":"Figure","type":"Plot"},"ticker":{"id":"e9afad1b-6392-4857-86c0-7312f49a1d33","type":"CategoricalTicker"}},"id":"2403a3d5-5411-4214-8886-0e0e64e3e963","type":"CategoricalAxis"},{"attributes":{"items":[{"id":"40d9bbe6-0532-4248-ad48-0465ff9245e3","type":"LegendItem"},{"id":"40cbc900-2b23-4f2b-aecb-ad72fdf240da","type":"LegendItem"},{"id":"aed82689-cddb-4c45-b98b-d90b8d83506a","type":"LegendItem"}],"location":"top_left","orientation":"horizontal","plot":{"id":"4181283a-62fa-42cf-a296-42bc2136d908","subtype":"Figure","type":"Plot"}},"id":"f46c6b16-a25e-4637-86a5-6818ade7d052","type":"Legend"},{"attributes":{"dimension":1,"plot":{"id":"4181283a-62fa-42cf-a296-42bc2136d908","subtype":"Figure","type":"Plot"},"ticker":{"id":"369a3910-2f6e-4e92-bd69-c40e091c04ab","type":"BasicTicker"}},"id":"1fa61d98-c9fc-4c9b-8f04-2f9fff4a6f5c","type":"Grid"}],"root_ids":["4181283a-62fa-42cf-a296-42bc2136d908"]},"title":"Bokeh Application","version":"0.12.9"}};
                    var render_items = [{"docid":"b964cc4d-9e89-4154-9cf7-5d268596bd17","elementid":"b5127d25-f109-4710-a3c2-0a4b1c6c31ae","modelid":"4181283a-62fa-42cf-a296-42bc2136d908"}];
                
                    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 embed document because BokehJS library is missing")
                        clearInterval(timer);
                      }
                    }, 10, root)
                  }
                })(window);
              });
            };
            if (document.readyState != "loading") fn();
            else document.addEventListener("DOMContentLoaded", fn);
          })();
        },
        function(Bokeh) {
          console.log("Bokeh: injecting CSS: https://cdn.pydata.org/bokeh/release/bokeh-0.12.9.min.css");
          Bokeh.embed.inject_css("https://cdn.pydata.org/bokeh/release/bokeh-0.12.9.min.css");
          console.log("Bokeh: injecting CSS: https://cdn.pydata.org/bokeh/release/bokeh-widgets-0.12.9.min.css");
          Bokeh.embed.inject_css("https://cdn.pydata.org/bokeh/release/bokeh-widgets-0.12.9.min.css");
          console.log("Bokeh: injecting CSS: https://cdn.pydata.org/bokeh/release/bokeh-tables-0.12.9.min.css");
          Bokeh.embed.inject_css("https://cdn.pydata.org/bokeh/release/bokeh-tables-0.12.9.min.css");
        }
      ];
    
      function run_inline_js() {
        
        for (var i = 0; i < inline_js.length; i++) {
          inline_js[i].call(root, root.Bokeh);
        }
        
      }
    
      if (root._bokeh_is_loading === 0) {
        console.log("Bokeh: BokehJS loaded, going straight to plotting");
        run_inline_js();
      } else {
        load_libs(js_urls, function() {
          console.log("Bokeh: BokehJS plotting callback run at", now());
          run_inline_js();
        });
      }
    }(window));
  };
  if (document.readyState != "loading") fn();
  else document.addEventListener("DOMContentLoaded", fn);
})();
