sub matrixwise_map(&@) { my $f = shift; # force array context since we're always dealing w/ matricies ( mapat( 2, $f, mapat(1, \&transpose, transpose(@_)) ) )[0]; }