added nunique method to index