which linux distribution are you using? If bash can't find xgraph, try to install it yourself. for debian/ubuntu users it'll be sudo apt-get install xgraph
for awk&xgraph try this workshop on google: https://sites.google.com/site/rsetnsworkshop/awk-xgraph