Short of that, traps in quiescent situations can add verisimilitude, but don't add any challenge to the play. So set the level to what the plot would have the trap-setter do. Set it low. And so on. The above applies only to traps which will be encountered in quiescent situations, say while the party is searching the place for loot after already killing all the monsters.
Active situations are different.
I'm talking the boiling oil over the portcullis kind of thing here. Such traps are usually part of fixed defenses that the defenders have had a long time to set up. As such, they can be much tougher than the defenders themselves. For these, consider the overall tactical challenge you are trying to give the party, and set the traps as high as necessary to achieve that challenge. You don't want the party buying things that will make the surrounding plot and combats trivial.