Rewrote the chart datasource in swift

And it works!