small changes to chart implementation