[R] Global variables
jpara3
j.para.fernandez at hotmail.com
Tue Jul 28 14:22:41 CEST 2015
Hi, I want to pass a variable value from one function to another, but not as
a function argument. For this propose I have put <<-, but it doesn´t work.
My code:
one<-function(){
a<<-"variable passed"
}
two<-function(){
print(a)
}
dos()
If I execute dos(), then the error message is:
Error in print(a) : object 'a' not found
Thanks"!
--
View this message in context: http://r.789695.n4.nabble.com/Global-variables-tp4710472.html
Sent from the R help mailing list archive at Nabble.com.
More information about the R-help
mailing list