(expr, given_condition=None, numsamples=1, **kwargs)
return results
Sampling version of density

    See Also
    ========
    density
    sampling_P
    sampling_E
Sampling version of density
Sampling version of density
def sampling_density(expr, given_condition=None, numsamples=1, **kwargs):
    """
    Sampling version of density

    See Also
    ========
    density
    sampling_P
    sampling_E
    """

    results = {}
    for result in sample_iter(expr, given_condition,
                              numsamples=numsamples, **kwargs):
        results[result] = results.get(result, 0) + 1
    return results
def sampling_density ( expr , given_condition = None , numsamples = 1 , * * kwargs ) : results = { } for result in sample_iter ( expr , given_condition , numsamples = numsamples , * * kwargs ) : results [ result ] = results . get ( result , 0 ) + 1 return results