def iqr_score(x, q = .25):
    """Inner Quantile Range Score
    
    The IQR score, the median centered data, scaled by the IQR. The inner quantile range can
    be flexibly set with the q parameter. A q further from .5 implies a larger range, and 
    therefore a smaller IQR Score. 
    
    Parameters
    ----------
    x : pandas.Series
    q : float between 0 and 1
        The quantile value for determining the IQR. A q of .25 yields a quartile
    """
    scale = x.quantile(1-q)-x.quantile(q)
    return(x-x.median()/scale)