A spectral approach to graphical representation of data