modified for google charts