def one_r2_ic(y, preds):
    """
    Compute the IC for one R-squared

    @param y: the outcome
    @param preds: the predictions based on a given subset of features

    @return the IC for R-squared
    """
    import sklearn.metrics as skm
    import numpy as np
    mse = skm.mean_squared_error(y_true=y, y_pred=preds)
    var = np.mean((y - np.mean(y)) ** 2)
    ic_mse = (y.reshape(preds.shape) - preds) ** 2 - mse
    ic_var = (y - np.mean(y)) ** 2 - var
    grad = np.array([1.0 / var, -1 * mse / var ** 2])
    return np.dot(grad, np.transpose(np.hstack(ic_mse, ic_var)))
