fix sub (#586); add gsub/3; add transpose/0.

Signed-off-by: William Langford <wlangfor@gmail.com>