[R] Help in building new function
ggrothendieck at gmail.com
Mon Aug 24 10:16:15 CEST 2009
1. Just enter
at the R console to see its source code (without comments). The source
tar.gz for R is found by googling for R, clicking on CRAN in left column
and choosing mirror. Or to view it online or get it via svn:
2. You want myarima's free variables to be found in the stats package so
set the environment of myarima like this:
environment(myarima) <- asNamespace("stats")
On Mon, Aug 24, 2009 at 2:18 AM, Ana Paula Mora<anamora31 at gmail.com> wrote:
> I've installed the precompiled binary for Windows. I need to use an existing
> function, but I want to introduce some slight changes to it.
> 1. Is there a way for me to find the source files through windows explorer?
> I know I can see it using edit(object name) but I want to know if I can see
> it via explorer in some location under the R directory.
> 2. I don´t want to modify the code of that function until I'm sure that my
> changes are not causing any harm. So, I got the R-2.9.1.tar.gz file and open
> the arima.R file. I change the name of the function to myarima, the name of
> the file to myarima.R, save it and the loaded it using the source command.
> So far, so good. When I try to execute my function I get the error message
> "Error in Delta %+% c(1, -1) : object 'R_TSconv' not found". So far, the
> only change I made is add a "Hello world" in the first line, so my change is
> not the source of the problem. Looks like my function (although it is
> exactly the same) is not being able to "see" this object.
> Can someone help me out? Am I missing something?
> Thanks a lot in advance.
> [[alternative HTML version deleted]]
> R-help at r-project.org mailing list
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
More information about the R-help