Skip to content

Instantly share code, notes, and snippets.

@DrSleep
Created June 11, 2014 11:01
Show Gist options
  • Save DrSleep/72efe3c62e4624c899fc to your computer and use it in GitHub Desktop.
Save DrSleep/72efe3c62e4624c899fc to your computer and use it in GitHub Desktop.
Liverpool
<!doctype HTML>
<meta charset = 'utf-8'>
<html>
<head>
<link rel='stylesheet' href='http://cdn.oesmith.co.uk/morris-0.4.2.min.css'>
<script src='http://ajax.googleapis.com/ajax/libs/jquery/1.9.0/jquery.min.js' type='text/javascript'></script>
<script src='http://cdnjs.cloudflare.com/ajax/libs/raphael/2.1.0/raphael-min.js' type='text/javascript'></script>
<script src='http://cdn.oesmith.co.uk/morris-0.4.2.min.js' type='text/javascript'></script>
<style>
.rChart {
display: block;
margin-left: auto;
margin-right: auto;
width: 1200px;
height: 500px;
}
</style>
</head>
<body>
<div id='chart3e06f141cac' class='rChart morris'></div>
<script type='text/javascript'>
var chartParams = {
"element": "chart3e06f141cac",
"width": 1200,
"height": 500,
"xkey": "Season",
"ykeys": [
"AwayGoals",
"HomeGoals"
],
"data": [
{
"Season": "1993-1994",
"AwayGoals": 26,
"HomeGoals": 33
},
{
"Season": "1994-1995",
"AwayGoals": 27,
"HomeGoals": 38
},
{
"Season": "1995-1996",
"AwayGoals": 24,
"HomeGoals": 46
},
{
"Season": "1996-1997",
"AwayGoals": 24,
"HomeGoals": 38
},
{
"Season": "1997-1998",
"AwayGoals": 26,
"HomeGoals": 42
},
{
"Season": "1998-1999",
"AwayGoals": 24,
"HomeGoals": 44
},
{
"Season": "1999-2000",
"AwayGoals": 23,
"HomeGoals": 28
},
{
"Season": "2000-2001",
"AwayGoals": 31,
"HomeGoals": 40
},
{
"Season": "2001-2002",
"AwayGoals": 34,
"HomeGoals": 33
},
{
"Season": "2002-2003",
"AwayGoals": 31,
"HomeGoals": 30
},
{
"Season": "2003-2004",
"AwayGoals": 26,
"HomeGoals": 29
},
{
"Season": "2004-2005",
"AwayGoals": 21,
"HomeGoals": 31
},
{
"Season": "2005-2006",
"AwayGoals": 25,
"HomeGoals": 32
},
{
"Season": "2006-2007",
"AwayGoals": 18,
"HomeGoals": 39
},
{
"Season": "2007-2008",
"AwayGoals": 24,
"HomeGoals": 43
},
{
"Season": "2008-2009",
"AwayGoals": 36,
"HomeGoals": 41
},
{
"Season": "2009-2010",
"AwayGoals": 18,
"HomeGoals": 43
},
{
"Season": "2010-2011",
"AwayGoals": 22,
"HomeGoals": 37
},
{
"Season": "2011-2012",
"AwayGoals": 23,
"HomeGoals": 24
},
{
"Season": "2012-2013",
"AwayGoals": 38,
"HomeGoals": 33
},
{
"Season": "2013-2014",
"AwayGoals": 31,
"HomeGoals": 42
}
],
"parseTime": false,
"id": "chart3e06f141cac",
"labels": [ "AwayGoals", "HomeGoals" ]
},
chartType = "Line"
new Morris[chartType](chartParams)
</script>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment