DefineResourceFunction

DefineResourceFunction[f]

defines a resource function that can be applied to arguments to give the same result as f[].

DefineResourceFunction[f,name]

uses name as the name of the resource function.

Details and Options

Examples

open allclose all

Basic Examples  (2)

Create a new ResourceFunction:

Create a ResourceFunction from a symbol:

Apply the resulting function to arguments:

Properties & Relations  (2)

Dependencies are automatically included in the resource:

The resource works even if the original definitions are cleared:

If no name is given for a pure function, an "Untitled" name is automatically generated:

Introduced in 2019
 (12.0)