Dear Kevin, I would convert the script into a function and add it to the R folder. This makes it easy to document the script using the standard R help files. Then add the function to the examples in the helpfile of the data in a \dontrun{}. Then it is clear to to user how the data was generated.
Best regards, ir. Thierry Onkelinx Instituut voor natuur- en bosonderzoek / Research Institute for Nature and Forest team Biometrie & Kwaliteitszorg / team Biometrics & Quality Assurance Kliniekstraat 25 1070 Anderlecht Belgium To call in the statistician after the experiment is done may be no more than asking him to perform a post-mortem examination: he may be able to say what the experiment died of. ~ Sir Ronald Aylmer Fisher The plural of anecdote is not data. ~ Roger Brinner The combination of some data and an aching desire for an answer does not ensure that a reasonable answer can be extracted from a given body of data. ~ John Tukey 2016-03-23 11:46 GMT+01:00 Enrico Schumann <e...@enricoschumann.net>: > On Tue, 22 Mar 2016, Kevin Coombes <kevin.r.coom...@gmail.com> writes: > > > Hi, > > > > I'm currently developing an R package that includes a small data set > > along with the functions that I want to export. I have an R script > > that generates the data set; the computation time is long (well, > > relative to the size of the data set). So, my plan is to run the > > script and save() the data set as an *.rda file that I can put in the > > data directory. (It is possible that some users of the package will > > _only_ be interested in the data set.) > > > > But, I'd like to keep the script with the package, both because it > > shows how to use some of the functions and because I might want to > > modify how the data set is generated in the future. My question: What > > is the "best practice" for where in the package directory structure to > > store such a script? > > > > Best, > > Kevin > > If the script is short, you could wrap it in \dontrun{...} > and put it into the Examples section of the Rd file that > describes the data. In this way people can quickly find the > code when they look up the data's documentation. > > > Kind regards > Enrico > > > -- > Enrico Schumann > Lucerne, Switzerland > http://enricoschumann.net > > ______________________________________________ > R-package-devel@r-project.org mailing list > https://stat.ethz.ch/mailman/listinfo/r-package-devel > [[alternative HTML version deleted]] ______________________________________________ R-package-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-package-devel