My take: Functions are for code that will be recurring. Expressions are for inserting code into other code.
Here's a simplified example:
Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA/Big Class.jmp" );
onewayFunc = function({dt,Yaxis, Xaxis}, {Default Local},
plot = dt << Oneway(
Y( eval(Yaxis) ),
X( eval(Xaxis) )
);
return(plot);
);
Yaxis = expr({Column("height"), Column("weight")});
Xaxis = expr(Column("sex"));
onewayFunc(dt,Yaxis,Xaxis);
This code could be accomplished without expressions, but using it as an example. In general I would say always use functions, until you meet an edge case where an expression will get the job done.
Expressions also have several useful helper functions making them useful for arithmatic and alegebra:
Names Default To Here( 1 );
Simplify Expr( Expr( 2 * 3 * a + b * (a + 3 - c) - a * b ) );
//6 * a + 3 * b + -1 * b * c