Detecting outliers from large datasets