chart rendering as a function