From ca76294d69fae8a4489a1ea8db378290af2e49ae Mon Sep 17 00:00:00 2001 From: Sean Fisher Date: Thu, 23 Feb 2012 22:26:37 -0500 Subject: [PATCH] Some quick docs --- example.html | 219 +++++++++++++++++++++++++++++++++++++++------------ 1 file changed, 170 insertions(+), 49 deletions(-) diff --git a/example.html b/example.html index e4d4ad1..f30b67c 100644 --- a/example.html +++ b/example.html @@ -1,56 +1,177 @@ - + + + + + + + + + morris.js - Documentation - -
- - - - - \ No newline at end of file + + +
+ +

Making good looking graphs shouldn't be as hard — or as ugly — as is it.

+ +

Formatting Dates with Quarters

+
+ + +

Formatting Dates with YYYY-MM

+
+ + +

Formatting Dates YYYY-MM-DD

+
+ + +

Example Script

+

We kept it simple so you should go wild with it.

+
+$(function () {
+     tax_data = [
+          {"period": "2012-10-01", "licensed": 3407, "sorned": 660},
+          {"period": "2011-08-12", "licensed": 3351, "sorned": 629},
+          {"period": "2011-03-03", "licensed": 3269, "sorned": 618},
+          {"period": "2010-08-08", "licensed": 3246, "sorned": 661},
+          {"period": "2010-05-10", "licensed": 3257, "sorned": 667},
+          {"period": "2010-03-14", "licensed": 3248, "sorned": 627},
+          {"period": "2010-01-10", "licensed": 3171, "sorned": 660},
+          {"period": "2009-12-10", "licensed": 3171, "sorned": 676},
+          {"period": "2009-10-07", "licensed": 3201, "sorned": 656},
+          {"period": "2009-09-25", "licensed": 3215, "sorned": 622},
+     ];
+     $('#graph-yyyy-mm-dd').hml({
+          data: tax_data,
+          xkey: 'period',
+          ykeys: ['licensed', 'sorned'],
+          labels: ['Licensed', 'SORN']
+     });
+})
+     
+
+ \ No newline at end of file