x | P(x)
dist
x
R/dist.R
conditional.dist.Rd
We just sample from x and place the sample in empirical_dist and then condition on it.
empirical_dist
# S3 method for class 'dist' conditional(x, P, n = 10000L, ...)
The distribution object.
The predicate function to condition the distribution on
The number of samples to generate for the MC estimate of the conditional distribution x | P. Defaults to 10000.
additional arguments to pass into P.
P