[Rd] data() statement in functions
Robin Hankin
r.hankin at noc.soton.ac.uk
Wed Aug 2 10:12:57 CEST 2006
Hi
I am writing a package in which a function needs a dataset (of
precomputed Stirling
numbers) to work. The .rda file resides in the data/ directory.
Toy example follows:
f <- function(x){
data(logS1)
. . . do stuff . . .
return(answer)
}
Is this a good way to do this?
What is best practice in such situations?
--
Robin Hankin
Uncertainty Analyst
National Oceanography Centre, Southampton
European Way, Southampton SO14 3ZH, UK
tel 023-8059-7743
More information about the R-devel
mailing list