[R] Error "could not find function"

Philipp Pagel
Sun, 04 Jan 2009 21:33:13 -0000

> I have copied a very simple function but when I try to call it I get an
error
> message "could not find function". The function file is named
addthree.r and
> I cd to the directory where the function is saved before calling it. What
am
> I doing wrong?

R does not look for funcitons to execute in random files. You
have to source() the file to execute the code -- i.e. define the
function in the current session. See also section 1.10 of the
manual ("An Introduction to R").

cu
	Philipp

--
Dr. Philipp Pagel
Lehrstuhl f?r Genomorientierte Bioinformatik
Technische Universit?t M?nchen
Wissenschaftszentrum Weihenstephan
85350 Freising, Germany