It operates at a loss of $7B, but that $7B is buying at least one thing: people traveling underground instead of aboveground.
Does this reduce congestion, traffic, or pollution? Maybe it allows for increased density or more sensible housing/business districts? More reliable commutes?
Given that the population is roughly 8 million and the gdp is roughly $1 trillion, it seems possible that NYC is coming out ahead on that $7B.