I am struggling with finding a code which allows me to create a named list containing 3 elements which are functions.
For the purpose of this question, it is necessary to download the purrr package.
the 3 functions, defined as elements of a named list, to be included are the following :
linear = function(x) x,
quadratic = function(x) (x - pi/2)^2 - pi/2
sinusoidal = function(x) sin(x)
but it seems a somewhat artificial requirement, given that we start with a vector of functions, and go to a named list, why go through the effort, why not a named vector ?