from mareforma.trust import (
Proposition, Direction, Prediction, TestType, DirectionOfInterest,
EffectEstimate, EffectType,
)
prop = Proposition(
subject="cell type A", relation="inhibitory connectivity onto",
object="cell type B", direction=Direction.INCREASES,
scope={"region": "cortex", "species": "mouse"},
)
plan = Prediction(
test_type=TestType.SUPERIORITY,
direction_of_interest=DirectionOfInterest.INCREASE, alpha=0.05,
)
# Analyst A on dataset_alpha: one independent line.
graph.assert_finding(prop, plan,
EffectEstimate(estimate_value=0.42, effect_type=EffectType.SMD,
ci_lower=0.18, ci_upper=0.66, ci_level=0.90, n_total=842),
data_id="dataset_alpha", generated_by="analyst/model-a/lab_a")
# Analyst B is a distinct run on a distinct dataset: a second independent line.
graph.assert_finding(prop, plan,
EffectEstimate(estimate_value=0.51, effect_type=EffectType.SMD,
ci_lower=0.20, ci_upper=0.82, ci_level=0.90, n_total=1104),
data_id="dataset_beta", generated_by="analyst/model-b/lab_b")
graph.query_frame(prop, min_status="PRELIMINARY")[0]["status"] # "CORROBORATED"