dpkg-query does have an option to do this, and its exit codes support your use case:
Report status of specified package. This just displays the entry in the installed package status
database. When multiple
package-name are listed, the requested status entries are separated by an
empty line, with the same order as specified on the argument list.
(note that it looks in the installed package status database, so it can't report on anything not installed — which is what you're after);
0: The requested query was successfully performed.
1: The requested query failed either fully or partially, due to no file or package being found (except
--control-show were such errors are fatal).
2: Fatal or unrecoverable error due to invalid command-line usage, or interactions with the system, such
as accesses to the database, memory allocations, etc.
(The manpage included in Debian 8 doesn't mention this, but
dpkg-query does behave like that even in Debian 8.)
So something like
dpkg-query -s package > /dev/null 2>&1
case $? in
echo $1 is installed
echo $1 is not installed
echo An error occurred
(turned into a function) would fit the bill as I understand it.