Nadal was upset by Australia's Nick Kyrgios in a Friday quarter-final at the WTA and ATP Cincinnati Masters, the last major tune-up for the US Open.
He wore black ribbons during an earlier match in tribute to the victims of twin vehicle ramming attacks in Spain that left 14 dead. A driver plowed his van through crowds on Barcelona's busy Las Ramblas boulevard on Thursday, and early Friday a car struck pedestrians in the Catalan seaside resort of Cambrils.
"I'm very, very sorry about what happened to all the victims, all the families, friends. Yeah, all my support. It's the moment to be together like a country and all the being together, we go for these kind of things."
Spanish rival Albert Ramos-Vinolas and Wimbledon women's champion Garbine Muguruza also wore black ribbons.
More From This Section
"All my support to Barcelona and especially to the people that are suffering a lot, for all the families of the victims," Nadal said. "Just keep going and sorry for everything."
"Amazing, positive news," Nadal said. "Being number one after all the things I've been going through the last couple of years is something unbelievable, so for me it's an amazing achievement to be back to that position.
"I'm very happy for that and in the last most important event of the season, I need to show why I am in that position now.
Nadal plans to rest through the weekend, then resume workouts for the final week before the Flushing Meadows fortnight begins.
"I think I am practicing well. I'm going to give my best during this week of practice," Nadal said. "I hope to be ready for New York.
"I believe that I did things well enough during the whole year to be ready to compete at the highest level of New York, so I'm looking forward to it.