Lipid phosphatase that specifically dephosphorylates the D-3 position of phosphatidylinositol 3-phosphate and phosphatidylinositol 3,5-bisphosphate, generating phosphatidylinositol and phosphatidylinositol 5-phosphate (PubMed:11733541, PubMed:12668758, PubMed:14690594, PubMed:21372139). Regulates the level of these phosphoinositides critical for various biological processes including autophagy initiation and autophagosome maturation (PubMed:35580604). {ECO:0000269|PubMed:11733541, ECO:0000269|PubMed:12668758, ECO:0000269|PubMed:14690594, ECO:0000269|PubMed:21372139, ECO:0000269|PubMed:35580604}. This is the function of MTMR2 (myotubularin related protein 2, Ensembl gene identifier ENSG00000087053).