Skip to content
Prev 48896 / 63424 Next

no visible binding for global variable for data sets in a package

The change would seem to be this

      \item \command{R CMD check} now by default checks code usage
      directly on the package namespace without loading and attaching
      the package and its suggests and enhances.

and perhaps the remedies could be stated more clearly?

Putting the data objects in the namespace would seem the obvious thing to do.

One oddity is that they are sort of in there already:
variable                             label
1   playerID                    Player ID code
2     yearID                              Year
3      stint                    Player's stint
4     teamID                              Team
5       lgID                            League
6          G                             Games
7  G_batting                   Games as batter
8         AB                           At Bats
9          R                              Runs
10         H                              Hits
11       X2B                           Doubles
12       X3B                           Triples
13        HR                          Homeruns
14       RBI                    Runs Batted In
15        SB                      Stolen Bases
16        CS                   Caught Stealing
17        BB                     Base on Balls
18        SO                        Strikeouts
19       IBB                 Intentional walks
20       HBP                      Hit by pitch
21        SH                    Sacrifice hits
22        SF                   Sacrifice flies
23      GIDP        Grounded into double plays
24     G_Old Old version of games (deprecated)

But then again, actually not:
Error in rbind(battingLabels, pitchingLabels, fieldingLabels) : 
  object 'battingLabels' not found

This is documented (:: can access datasets made available by lazy-loading), but it sort of suggests that we might want to improve consistency in this area. 

-pd
On 27 Aug 2014, at 11:24 , Martin Maechler <maechler at stat.math.ethz.ch> wrote: