causalincentives / pycid

Library for graphical models of decision making, based on pgmpy and networkx
Apache License 2.0
96 stars 13 forks source link

query, expected_value should accept dictionaries with lowercase variable names #48

Closed tom4everitt closed 3 years ago

tom4everitt commented 3 years ago

Since this is how parent values are specified, it would make methods such as impute_optimal_policy and impute_conditional_expectation simpler.

It would also remove code duplication, as the code for converting to uppercase variable names would only reside in one place

tom4everitt commented 3 years ago

Done (though it's somewhat ugly to have to keep converting between lowercase and uppercase names). https://github.com/causalincentives/pycid/commit/c1bfcac6f3580b8b7ad1219ba2ad2ed094502954