kcat/utils.py
def pgen(X):
    """Returns a function that applies `pgen` to each element in `X`.

    :param X: Matrix where each row is an example and each column a categorical
        attribute.

    :returns: Function that applies pgen to any matrix.
    """
    pgen = get_pgen(X)
    return lambda Y: apply_pgen(pgen, Y)
Returns a function that applies `pgen` to each element in `X`.

    :param X: Matrix where each row is an example and each column a categorical
        attribute.

    :returns: Function that applies pgen to any matrix.
    
Returns a function that applies `pgen` to each element in `X`.
Returns a function that applies ` pgen ` to each element in ` X ` .
def pgen(X):
    pgen = get_pgen(X)
    return lambda Y: apply_pgen(pgen, Y)
def pgen ( X ) : pgen = get_pgen ( X ) return lambda Y : apply_pgen ( pgen , Y )
Returns a function that applies `pgen` to each element in `X`.
Returns a function that applies ` pgen ` to each element in ` X ` .
"""Returns a function that applies `pgen` to each element in `X`.

    :param X: Matrix where each row is an example and each column a categorical
        attribute.

    :returns: Function that applies pgen to any matrix.
    """
Function that applies pgen to any matrix.
Function that applies pgen to any matrix .
X
Matrix where each row is an example and each column a categorical
attribute.
Matrix where each row is an example and each column a categorical attribute .