Updated with correlation and similarity functions