EconML
EconML copied to clipboard
Error with estimate_effect method using DMLOrthoForest
Hi everyone,
I am using the method estimate_effect with DMLOrthoForest, for a model with two common causes (W1 and W2, in my dataset) and one instrumental variable (instruments), but I get the error: "ValueError: Expected 2D array, got scalar array instead: array=None. Reshape your data either using array.reshape(-1, 1) if your data has a single feature or array.reshape(1, -1) if it contains a single sample."
I appreciate a lot if anyone can explain to me how to understand this error and what is happening. I suspect the problem is originated in the definition of the causal model, but I am not sure, and I want to know what is the cause of this error.
Here is the minimal working example: