I use both. I think this is really a play group level preference and I think it's a really odd topic. Theres two real reasons.
First about, you should do both. What you roll in private and in public are powerful tools for manipulating player's emotions. Just blanket rolling in one way or another is limiting that tool needlessly. If I always roll in private, opening up a roll to the players can have a huge impact on the tension. In the reverse, rolling behind a screen when you normally roll in the open can do the same. Anytime the norm changes, your players will notice. So you should use the opposite method from time to time to "toy" with your players. It's a really neat trick I rarely see DMs use.
Secondly, I feel this, in many instances, is about a lack of DM trust. Like so much of the discussion on this board, if you trust your playgroup and DM this is a non-factor. And I believe this is a completely ineffective tool at band-aiding DM trust.
For example, many here cite fudging and a dislike for it as to why rolling in the open is better for them. But to be honest, if you want to fudge, its inefficient to fudge the dice rolls. You go to the source, you fudge the stat-block. Fudging HP is far more effective at balancing the pacing and feel of combat than fudging dice numbers up or down. Fudging HP down solves nearly every non-adversarial issue a DM can face; from the enemy doing too much damage to the enemy not doing enough. It solves them by getting you out of the combat quickly, all with the perk of the PCs feeling good about winning that combat.
Fudging a combat through individual dice rolls requires more "fudging." If I have to fudge a "to hit" roll one round, chances are I will have to fudge the same roll a second time soon thereafter. So if a DM is in such a position where they cannot fudge the statblock to solve the issue, they likely made another mistake that caused that situation. A common one I see is when a DM comments on the enemy HP directly or indirectly in a way that prevents them frin changing the HP later. DMs talking too much is the cause of a lot of issues, they really need to shut up about the game in general. Rolling in the open, in this case, just forces the manifestation of the mistake in game. It doesn't actually leave the fate to the dice, because the DM's encounter balance decided it hours prior.
So I think this is just a weird discussion about DM trust. Because you can't remove the DM's intent from the encounter, you can just mask it to the extent that placates the player' skepticism. And for that reason, it will vary from play group to play group because some play groups are far more skeptical than others. People on here seem to error on the side of that skepticism.