Change graph percents

--> change the classes to make it easier to display class with ruby
--> change the data type to json for the array return