lp, it's very hard to answer your questions as we do not see the whole code. To understand the question and answer it correctly, we need a sample PROJECT (all files) we can launch on our computers.
Just looking at this post, we can say that the data could be not in a numeric format - but we cannot say it for sure as we do not have the code you use to calculate your cell values.