jQuery.fn.scrollableAddClones = function() {
  // grab scrollable plugin
  var scrollable;
  if (!(scrollable = $(this).data('scrollable')) || !scrollable.getConf().circular)
    return;
  // grab scrollable elements and remember it's count
  var nodes = scrollable.getItems();
  var length = nodes.length;
  // grab class for the nodes
  var clonedClass = scrollable.getConf().clonedClass;
  // get wrap object to append the clones to
  var wrap = scrollable.getItemWrap();
  // add 8 clone objects - start at 1 as element[0] was already cloned by scrollable()
  for (var i = 1; i <= 8; i++) {
    nodes.eq(i % length).clone().addClass(clonedClass).appendTo(wrap);
  }
}

$(function(){ 
$(document).ready(function() {    
	var root = $(".scrollable").scrollable({ 
        circular: true
    }).autoscroll({ 
    	autoplay: true,
    	interval: 4500,
    	autopause: false
    });
    
    window.api = root.data("scrollable");
    
    $('.scrollable').scrollableAddClones();
	})   
}); 
