PS4 comparison is bit difficult when you consider resolution, inclusion of DLSS, and the fact that the instructions performed per cycle will be better. That and amount of memory and speed of said memory. The reality, is the Switch 2 based off of information, will be a combination of being better overall, but may be held back by clock speeds, so could in theory perform worse in other areas, but better in others. It's really not a 1:1 comparison (plus taking into the fact we're talking about different architectures and different gpu manufacturers, too). It's also why the Switch, despite being overall better than Wii U, PS3, and 360, could struggle in some areas (due to memory read speeds and such).
There's no simple answer on this, and this is true for both docked and handheld/portable mode.
The console will be a generation up from PS4 regardless in every aspect. Whether or not it out performs it in every element will remain to be seen and we won't get an idea until the console itself releases and we get finalized specs (as right now, we only have limited information, even with the speeds in the leaks).