def check_generate(name): check_cm(name) cm = ComponentModel(name) cm.realize_hp() params = cm.generate_post() b = BasicDistribution(name, pm=params) b.sample_data()
def check_data_prob(name): b = BasicDistribution(name) p = b.data_prob(b.sample_data()) ok_(p >= 0.)
def check_sample_N(name): b = BasicDistribution(name) x = b.sample_data(10) assert_equal(len(x), 10)
def check_sample(name): b = BasicDistribution(name) b.sample_data()