Added feature extraction and evaluation function