Clearly, I would have to check for each input argument to be ~isempty(), or ~isnan(), which could be another technique. However, in this way, a 1-line function becomes a 5-lines function.
No, it would become at most a 2-line function. You would naturally write a separate check_for_unknowns.m mfunction that checks all the arguments for Unknowns and re-use that utility in every function that needs it:
fun(1, 2, Unknown, 4);
function x = fun(a, b, c, d)
x = a + b + c + d;
assert(all(map),'Unknown variable type entered');
Moreover, anonymous functions, which can only be one-line, would benefit from the usage of such "Unknown" class.
You can extend this idea to anonymous functions by writing the following additional utility mfile,
and now you can do 1-line things like,
>> fun=@(a,b,c,d) a+b+c+d;