graph in HTML5  and JavaScript