def import_example(data='random', n_samples=1000, n_feat=10):
    """Import example dataset from sklearn.

    Parameters
    ----------
    data : str
        'random' : str, two-class
        'breast' : str, two-class
        'titanic': str, two-class
        'iris' : str, multi-class
    n_samples : int, optional
        Number of samples to generate. The default is 1000.
    n_feat : int, optional
        Number of features to generate. The default is 10.

    Returns
    -------
    tuple (X,y).
        X is the dataset and y the response variable.

    """
    try:
        from sklearn import datasets
    except:
        print('This requires: <pip install sklearn>')
        return None, None
    if data == 'iris':
        X, y = datasets.load_iris(return_X_y=True)
    elif data == 'breast':
        X, y = datasets.load_breast_cancer(return_X_y=True)
    elif data == 'titanic':
        X, y = datasets.fetch_openml('titanic', version=1, as_frame=True,
            return_X_y=True)
    elif data == 'random':
        X, y = datasets.make_classification(n_samples=n_samples, n_features
            =n_feat)
    return X, y
