Estimation and Inference in Panel Structure Models