def getSamplerFun(sampler, distributions):
    """
    get distributions' function by class sampler.
    Inputs:
        sampler       : sampler class, pydpm._sampler.Basic_Sampler;
        distributions : [str] list of distributions;
    Outputs:
        funcs         : {str: fun}, dict of distributions' functions;
    """
    # get funcs
    funcs = {}
    for dist in distributions:
        funcs[dist] = getattr(sampler, dist)

    return funcs