How to install downloaded node-v6.9.2-linux-x64.tar.xz file in ubuntu 14.04

According to the official website you can install node-v6.x as follow:

sudo apt-get install curl
curl -sL https://deb.nodesource.com/setup_6.x | sudo -E bash -
sudo apt-get install -y nodejs

Install Node.js (node-v6.9.4-linux-x64.tar.xz)

Download and extract the Node.js "Linux Binaries" package. For example, if you downloaded version 6.9.4 for 64-bit you could install Node.js into /opt:

cd /opt
tar -Jxf node-v6.9.4-linux-x64.tar.xz

Set PATH to include Node.js:

export PATH=/opt/node-v6.9.4-linux-x64/bin:$PATH