search for: gobalenv

Displaying 2 results from an estimated 2 matches for "gobalenv".

Did you mean: globalenv
2013 Oct 07
1
search for variable in package in .GlobalEnv first
...- TYPE where the variable TYPE is initialized in the package to e.g. "exponential" (SIM::TYPE == "exponential"). Now, I want to give the user the option of specifying the variable TYPE, but to the effect, that if the user does not define a variable TYPE in the user workspace (.GobalEnv), the one in the namespace from the package is used. In other words, I want to look first in the workspace, and then in SIM:: for the variable TYPE. How can do this? Thanks, Rainer -- Rainer M. Krug email: RMKrug<at>gmail<dot>com -------------- next part -------------- A non-text...
2005 Sep 27
3
Dummy quesion about environment
Hi, I'm trying to understand environment object in R. I used the example: f <- function(x) { y <- 10 g <- function(x) x + y return(g) } h <- f() h(3) then i saw that f return an environment > h function(x) x + y <environment: 01B28570> but I coudn't access to x and y object in that environment: I tried