Tyler Cowen directed me to a post by Brad Setser, with this very interesting observation:
I feel I am at risk of becoming a bit shrill on the topic of tax and trade, but it is very hard--in my view--to understand a lot of the trade data without understanding how heavily a lot of trade is influenced by what might be termed chains of tax arbitrage that have nothing to do with conventional tariffs. The trade flows linked to such tax arbitrage are in my view why the U.S. runs a large trade deficit in pharmaceuticals overall, and why most of the deficit is with places like Ireland and Switzerland. And the U.S. would technically run a trade deficit with Puerto Rico if Puerto Rico were disaggregated from the U.S.--even though the ships that sail from the U.S. to Puerto Rico sail to Puerto Rico full and come back almost empty. Welcome to the world of transfer pricing!
Puerto Rico's economy was a disaster area even before Maria, but at least they almost always run trade surpluses:
Seriously, trade data is so misleading that I sometimes wonder if we would be better off not even collecting it, just as we don't waste time calculating the trade balance between North and South Dakota.