to make you understand this statement i need the data which you are using inside td,i mean innerHTML of your TD,because your code is doing that only,but for now i will take one sample and will explain,see the line below
this content would be return as nodeValue is used,there is also property called nodeType which may result in "#text"
so the "nodeValue" property is a read/write property that reflects the current value of a
node. For text nodes, the content of the node is returned, while for
attribute nodes, the attribute value. Null is returned for Document
and element nodes. Use this property to alter the contents of a text
or attribute node.
let me know