undefined value in bar and line chart