# Sampling labeled data for anomaly detection

I'm currently working on a project that requires the use of unsupervised anomaly detection, but I'm unable to find a relevant data set, so I'm considering the following option:

Assuming I have a data set $$X$$ of $$m$$ examples labeled using $$K$$ classes. Let $$X(k)$$ be the subset of $$X$$ where all examples are labeled as $$k$$, and $$k_{max}$$ be the larget class. Can I use $$X(k_{max})$$ as a training set for an anomaly detector, whose task is to flag elements who weren't labeled as $$k_{max}$$, as an anomaly? Using $$p << [m - size(X(k))]$$ of the remaining examples in $$X$$ for cv and test sets as the anomalous examples.