YUI.add("axis-base",function(e,t){var s=e.Lang;function a(){}a.ATTRS={styles:{getter:function(){return this._styles=this._styles||this._getDefaultStyles(),this._styles},setter:function(t){this._styles=this._setStyles(t)}},graphic:{}},a.NAME="renderer",a.prototype={_styles:null,_setStyles:function(t){var e=this.get("styles");return this._mergeStyles(t,e)},_mergeStyles:function(t,a){a=a||{};var i=e.merge(a,{});return e.Object.each(t,function(t,e){a.hasOwnProperty(e)&&s.isObject(t)&&!s.isFunction(t)&&!s.isArray(t)?i[e]=this._mergeStyles(t,a[e]):i[e]=t},this),i},_copyObject:function(t){var e,a,i={};for(e in t)t.hasOwnProperty(e)&&("object"!=typeof(a=t[e])||s.isArray(a)?i[e]=a:i[e]=this._copyObject(a));return i},_getDefaultStyles:function(){return{padding:{top:0,right:0,bottom:0,left:0}}}},e.augment(a,e.Attribute),e.Renderer=a,e.AxisBase=e.Base.create("axisBase",e.Base,[e.Renderer],{initializer:function(){this.after("minimumChange",e.bind(this._keyChangeHandler,this)),this.after("maximumChange",e.bind(this._keyChangeHandler,this)),this.after("keysChange",this._keyChangeHandler),this.after("dataProviderChange",this._dataProviderChangeHandler)},getOrigin:function(){return this.get("minimum")},_dataProviderChangeHandler:function(){var t,e=this.get("keyCollection").concat(),a=this.get("keys");if(a)for(t in a)a.hasOwnProperty(t)&&delete a[t];e&&e.length&&this.set("keys",e)},_updateMinAndMax:function(){},GUID:"yuibaseaxis",_type:null,_setMaximum:null,_setMinimum:null,_data:null,_updateTotalDataFlag:!0,_dataReady:!1,addKey:function(t){this.set("keys",t)},_getKeyArray:function(t,e){for(var a,i=0,n=[],r=e.length;i<r;++i)a=e[i],n[i]=a[t];return n},_updateTotalData:function(){var t,e=this.get("keys");for(t in this._data=[],e)e.hasOwnProperty(t)&&(this._data=this._data.concat(e[t]));this._updateTotalDataFlag=!1},removeKey:function(t){var e=this.get("keys");e.hasOwnProperty(t)&&(delete e[t],this._keyChangeHandler())},getKeyValueAt:function(t,e){var a=NaN,i=this.get("keys");return i[t]&&s.isNumber(parseFloat(i[t][e]))&&(a=i[t][e]),parseFloat(a)},getDataByKey:function(t){var e,a,i,n,r=this.get("keys");if(s.isArray(t))for(e={},i=t.length,a=0;a<i;a+=1)r[n=t[a]]&&(e[n]=this.getDataByKey(n));else e=r[t]||null;return e},getTotalMajorUnits:function(){return this.get("styles").majorUnit.count},getEdgeOffset:function(t,e){e=this.get("calculateEdgeOffset")?e/t/2:0;return e},_keyChangeHandler:function(){this._updateMinAndMax(),this._updateTotalDataFlag=!0,this.fire("dataUpdate")},_getDefaultStyles:function(){return{majorUnit:{determinant:"count",count:11,distance:75}}},_maximumGetter:function(){var t=this.get("dataMaximum");return 0===this.get("minimum")&&0===t&&(t=10),s.isNumber(this._setMaximum)&&(t=this._setMaximum),parseFloat(t)},_maximumSetter:function(t){return this._setMaximum=parseFloat(t),t},_minimumGetter:function(){var t=this.get("dataMinimum");return s.isNumber(this._setMinimum)&&(t=this._setMinimum),parseFloat(t)},_minimumSetter:function(t){return this._setMinimum=parseFloat(t),t},_getSetMax:function(){return s.isNumber(this._setMaximum)},_getCoordsFromValues:function(t,e,a,i,n,r){for(var s=[],u=i.length,o=0;o<u;o+=1)s.push(this._getCoordFromValue.apply(this,[t,e,a,i[o],n,r]));return s},_getDataValuesByCount:function(t,e,a){for(var i=[],n=e,r=t-1,s=(a-e)/r,u=0;u<r;u+=1)i.push(n),n+=s;return i.push(a),i},_getSetMin:function(){return s.isNumber(this._setMinimum)}},{ATTRS:{calculateEdgeOffset:{value:!1},labelFunction:{valueFn:function(){return this.formatLabel}},keys:{value:{},setter:function(t){var e,a,i={},n=this.get("dataProvider");if(s.isArray(t))for(a=t.length,e=0;e<a;++e)i[t[e]]=this._getKeyArray(t[e],n);else if(s.isString(t))(i=this.get("keys"))[t]=this._getKeyArray(t,n);else for(e in t)t.hasOwnProperty(e)&&(i[e]=this._getKeyArray(e,n));return this._updateTotalDataFlag=!0,i}},type:{readOnly:!0,getter:function(){return this._type}},dataProvider:{setter:function(t){return t}},dataMaximum:{getter:function(){return s.isNumber(this._dataMaximum)||this._updateMinAndMax(),this._dataMaximum}},maximum:{lazyAdd:!1,getter:"_maximumGetter",setter:"_maximumSetter"},dataMinimum:{getter:function(){return s.isNumber(this._dataMinimum)||this._updateMinAndMax(),this._dataMinimum}},minimum:{lazyAdd:!1,getter:"_minimumGetter",setter:"_minimumSetter"},setMax:{readOnly:!0,getter:"_getSetMax"},setMin:{readOnly:!0,getter:"_getSetMin"},data:{getter:function(){return this._data&&!this._updateTotalDataFlag||this._updateTotalData(),this._data}},keyCollection:{getter:function(){var t,e=this.get("keys"),a=[];for(t in e)e.hasOwnProperty(t)&&a.push(t);return a},readOnly:!0},labelFunctionScope:{}}})},"patched-v3.18.7",{requires:["classnamemanager","datatype-number","datatype-date","base","event-custom"]});