Is there a case where nails are better than screws, from an engineering/structural standpoint?
Screws are a "superior" fastener over a nail (they have far superior tensile strength) - especially if you're talking about screwing down decking.

However there are many scenarios where a nail is the proper fastener for the application (attaching joists is one example - screws are brittle and will fail when subjected to the forces of a shear loaded application)

Using your deck example - you should use nails to attach the joists to the deck framing but use screws to fasten down the decking itself.

Also keep in mind that screws take a longer time to install - think of a nail gun versus a drill...