This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
YUI({ | |
defaultGraphicEngine: (window.location.search.match(/[?&]defaultGraphicEngine=([^&]+)/) || [])[1] || 'svg', | |
filter: (window.location.search.match(/[?&]filter=([^&]+)/) || [])[1] || 'raw' | |
}).use('axis-numeric-base', 'axis-category-base', 'series-candlestick', function (Y) | |
{ | |
var myDataValues = [ | |
{date:"5/1/2010", open:2000, high:3700, low:200, close: 2300}, | |
{date:"5/2/2010", open:1500, high:9100, low:100, close: 500}, | |
{date:"5/3/2010", open:400, high:3100, low:1500, close: 2000}, | |
{date:"5/4/2010", open:3200, high:3900, low:2800, close: 2900}, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var histogramDrawSeries = function() { | |
if(this.get("xcoords").length < 1) | |
{ | |
return; | |
} | |
var style = this._copyObject(this.get("styles").marker), | |
graphic = this.get("graphic"), | |
setSize, | |
calculatedSize, | |
xcoords = this.get("xcoords"), |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var myDataValues = [ | |
{day:"Monday", taxes:2000}, | |
{day:"Tuesday", taxes:50}, | |
{day:"Wednesday", taxes:4000}, | |
{day:"Thursday", taxes:200}, | |
{day:"Friday", taxes:2000} | |
], | |
getDonutChart = function(cfg) | |
{ | |
var pieGraph = new Y.Chart(cfg), |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
YUI.add('charts-interactive-annotations', function (Y) { | |
/** | |
* Allows for the creation of annotations for a chart. | |
* | |
* @module charts-interactive-annotations | |
*/ | |
/** | |
* Creates a marker that can be used as an annotation. | |
* | |
* @class AnnotationMarker |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
YUI({filter: 'raw'}).use('graphics', function (Y) | |
{ | |
var dashArray = [4, 2], | |
drawDashedLine = function(path, xStart, yStart, xEnd, yEnd, dashSize, gapSize) | |
{ | |
dashSize = dashSize || 10; | |
gapSize = gapSize || 10; | |
var segmentLength = dashSize + gapSize, | |
xDelta = xEnd - xStart, | |
yDelta = yEnd - yStart, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if(Y.VMLShape) { | |
Y.Shape.prototype._getStrokeProps = function() | |
{ | |
var props, | |
stroke = this.get("stroke"), | |
strokeOpacity, | |
dashstyle, | |
dash = "", | |
val, | |
i = 0, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="utf-8"> | |
<title>Dual Axes Chart</title> | |
<style type="text/css"> | |
#mychart { | |
width: 700px; | |
height: 350px; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Y.ChartLegend.prototype._drawLegend = function() | |
{ | |
var chart = this.get("chart"), | |
node, | |
seriesCollection = chart.get("seriesCollection"), | |
series, | |
styles, | |
padding, | |
itemStyles, | |
seriesStyles, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//Unable to parse | |
//var data =[{"records":"[{\"category\":\"doc4\",\"value\":1},{\"category\":\"heute rating dokument2\",\"value\":2},{\"category\":\"rating Dokument1\",\"value\":1}]","singleChartAxes":"{\"yAxesTitle\":\"Bewertung3_single\",\"maxNumberOfCounts\":2}","ratingTooltip":"{\"ratingTooltip\":\"merci\"}"}]; | |
//manually converterted into vars | |
var jsonValues = [{"category":"doc4","value":1},{"category":"heute rating dokument2","value":2},{"category":"rating Dokument1","value":1}], | |
chartAxesObject = {"yAxesTitle":"Bewertung3_single","maxNumberOfCounts":2}, | |
jsonRatingTooltip = {ratingTooltip:"merci"}; | |
//Chart Legend | |
var myLegend = { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Y.CartesianChart.prototype._dataProviderChangeHandler = function(e) { | |
var dataProvider = e.newVal, | |
axes, | |
i, | |
axis; | |
this._seriesIndex = -1; | |
this._itemIndex = -1; | |
this._drawing = true; | |
if(this instanceof Y.CartesianChart) | |
{ |
NewerOlder