I am surprised a DND thingy or something of the purpose was never implemented. Talking about NL and NH collectively, I have had a lot of barge ins, like I am not even gonna bother counting...
I've already gotten my first one in New Horizons since restarting my island last month.
I reset New Leaf last night again, since my last town felt off to me, but I know they will eventually start happening. They usually start happening after three weeks of starting the town, maybe a bit more. And something I have noticed about New Leaf...these barge-ins can only happen weekly, though I am not sure if this only pertains to a particular villager, or if they can only be a weekly thing in general.
As for the frequency in New Horizons, I am unsure, but I will keep an eye out. People were saying that you could get multiple barge-ins in the same day (which hasn't happened to me), but I do not know how often a particular villager can barge-in. I reckon it is weekly like in New Leaf.
I have a massive love-hate relationship with this. On one hand, I love having these different interactions with villagers...I just HAAAAATE how these villagers choose to do so at the most atrocious times. Having some sort of DND thing would have been a good compromise.
It is not as bad in New Horizons, since they implemented the build-mode feature from Happy Home Designer and the villagers won't bother you until you exit out of it, but in New Leaf...it is a nightmare to decorate. .__. NTM, they can barge in even though they were already over earlier that day (as long as the first one isn't a barge-in). They can also barge in a night, but this could partain to New Horizons too.