Skip to content
Prev 25167 / 63424 Next

Problem with accessing internal variable in package.

This is my first package, and clearly, I'm missing something.

After reading again manuals about name spaces and hooks, I have defined the
function .onLoad,
which implicitly assigns all internal variables with <<-
Then I have deleted previous package directory and changed the call to
package.skeleton

package.skeleton(name="ac9",
                 list=c(ls(pattern="(AB2)"),
                       
"plot.C","read.AC9.data","EstimC","plot.AC9",".onLoad"),
                  namespace=TRUE,force=TRUE)

It has created file ac9/R/ac9-internal.R, containing the function .onLoad,
however, its body completely differs from that I have defined before.
Vladimir Eremeev wrote: