added example of custom function