Given this dataset with missing and anomalous values, write a script to prepare it for a random forest classifier.
Implement prepare_dataset(rows, target_column), where rows is a list of dictionaries containing numeric, categorical, or None values. Return a dictionary with one-hot-encoded feature rows and labels. Treat numeric values outside the 1.5 IQR range as missing, replace missing numeric values with the median, replace missing categorical values with the mode, and omit rows whose target is missing. Preserve the target values unchanged.
def prepare_dataset(rows, target_column):