New in this version:
o Cleaned up the code a bit. It's still a bit of a mess, though...
o Added scaling to graphs
o Only outputs the graph div, so it can be called by something else making the rest of the webpage.
Note: the code to html converter zaps the indenting. You may want to pass it through a pretty printer.