Skip to content
Prev 177248 / 398513 Next

static variable?

dear R experts:

does R have "static" variables that are local to functions?  I know
that they are usually better avoided (although they are better than
globals).

However, I would like to have a function print how often it was
invoked when it is invoked, or at least print its name only once to
STDOUT when it is invoked many times.

possible without <<- ?

sincerely,

/iaw