working on writing up inference