How create function show or hide the node?

This was already answered in the original topic: How to hide nodes?