recursive_apply function

Simple rapply version that deals with NULL values.