function scroll(els) {
    sections = els;

    // when window is scrolled call
    // position. When it is resized
    // call resize.
    d3.select(window)
      .on("scroll.scroller", position)
      .on("resize.scroller", resize);

    // manually call resize
    // initially to setup
    // scroller.
    resize();

    // hack to get position
    // to be called once for
    // the scroll position on
    // load.
    d3.timer(function() {
      position();
      return true;
    });
  }
/**
   * scroll - constructor function.
   * Sets up scroller to monitor
   * scrolling of els selection.
   *
   * @param els - d3 selection of
   *  elements that will be scrolled
   *  through by user.
   */
constructor function.
Sets up scroller to monitor
scrolling of els selection.

@param els - d3 selection of
elements that will be scrolled
through by user.
constructor function . Sets up scroller to monitor scrolling of els selection . @param els - d3 selection of elements that will be scrolled through by user .
function scroll(els) {
    sections = els;
    d3.select(window)
      .on("scroll.scroller", position)
      .on("resize.scroller", resize);
    resize();
    d3.timer(function() {
      position();
      return true;
    });
  }
function scroll ( els ) { sections = els ; d3 . select ( window ) . on ( "scroll.scroller" , position ) . on ( "resize.scroller" , resize ) ; resize ( ) ; d3 . timer ( function ( ) { position ( ) ; return true ; } ) ; }
scroll - constructor function.
scroll - constructor function .
// when window is scrolled call // position. When it is resized // call resize. // manually call resize // initially to setup // scroller. // hack to get position // to be called once for // the scroll position on // load.