node_data function

Insert node data attributes during node creation