From ac26c455b8a576501ab01a969ef0a8038f608c97 Mon Sep 17 00:00:00 2001 From: Christophe Genolini Date: Thu, 15 Oct 2009 00:00:00 +0000 Subject: [PATCH] version 0.5.2 --- DESCRIPTION | 16 ++++++++-------- DESCRIPTION_EX | 10 ++++++++++ NAMESPACE | 2 +- R/progClassic.R | 19 ++++++++++--------- divers/progClassic1.R | 6 ++++++ divers/testsProgClassic1.R | 9 +++++++++ main.R | 5 +++++ man/dataAges.Rd | 2 ++ man/packClassic-package.Rd | 6 ++++-- tests/testsProgClassicRCoreTeam.R | 10 ++++++++++ testsDev/testsProgClassic.R | 16 ++++++++-------- 11 files changed, 73 insertions(+), 28 deletions(-) create mode 100755 DESCRIPTION_EX create mode 100755 divers/progClassic1.R create mode 100755 divers/testsProgClassic1.R create mode 100755 main.R create mode 100755 tests/testsProgClassicRCoreTeam.R diff --git a/DESCRIPTION b/DESCRIPTION index a4447f5..d9375d0 100755 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,16 +1,16 @@ Package: packClassic Type: Package -Title: Toy Pack Classic -Version: 0.5.1 -Date: 2009-05-23 -Author: Author: Christophe Genolini (and some helpfull readers...) -Maintainer: +Title: Toy example of Pack Classic +Version: 0.5.2 +Date: 2009-10-15 +Author: Christophe Genolini +Maintainer: Christophe Genolini Description: This package comes to illustrate the book "Petit Manuel de Programmation Orientee Objet sous R" License: GPL (>= 2.0) LazyLoad: yes Depends: graphics -URL: www.r-project.org,christophe.genolini.free.fr/webTutorial -Packaged: 2009-05-23 11:12:29 UTC; Christophe +URL: www.r-project.org +Packaged: 2009-10-11 18:17:29 UTC; Christophe Repository: CRAN -Date/Publication: 2009-05-24 08:36:32 +Date/Publication: 2009-10-11 18:30:13 diff --git a/DESCRIPTION_EX b/DESCRIPTION_EX new file mode 100755 index 0000000..0c2d96c --- /dev/null +++ b/DESCRIPTION_EX @@ -0,0 +1,10 @@ +Package: packClassic +Type: Package +Title: What the package does (short line) +Version: 1.0 +Date: 2008-07-22 +Author: Who wrote it +Maintainer: Who to complain to +Description: More about what it does (maybe more than one line) +License: What license is it under? +LazyLoad: yes diff --git a/NAMESPACE b/NAMESPACE index f907e65..70ba8df 100755 --- a/NAMESPACE +++ b/NAMESPACE @@ -1,6 +1,6 @@ - export("publicA", ".publicB", "publicC" ) + importFrom(graphics,plot) diff --git a/R/progClassic.R b/R/progClassic.R index 3a8d3af..4e2692d 100755 --- a/R/progClassic.R +++ b/R/progClassic.R @@ -1,9 +1,10 @@ -# ################################################################ -### ProgClassic .R ### -# ################################################################ -publicA<-function(x){plot(x+1)} -privateA<-function(x){x+2} -.publicB<-function(x){x+10} -.privateB<-function(x){x+20} -publicC<-function(x){publicA(privateA(x))} -privateC<-function(x){.publicB(.privateB(x))} +###################################################### +### ProgClassic.R ### +###################################################### + +publicA <- function(x){plot(x+1)} +privateA <- function(x){x+2} +.publicB <- function(x){x+10} +.privateB <- function(x){x+20} +publicC <- function(x){publicA(privateA(x))} +privateC <- function(x){.publicB(.privateB(x))} diff --git a/divers/progClassic1.R b/divers/progClassic1.R new file mode 100755 index 0000000..38053b4 --- /dev/null +++ b/divers/progClassic1.R @@ -0,0 +1,6 @@ +###################################################### +### ProgClassic.R ### +###################################################### + +publicA <- function(x){plot(x+1)} +privateA <- function(x){x+2} diff --git a/divers/testsProgClassic1.R b/divers/testsProgClassic1.R new file mode 100755 index 0000000..3ca93e9 --- /dev/null +++ b/divers/testsProgClassic1.R @@ -0,0 +1,9 @@ +########################################## +### Nom du programme : testClassique.R ### +########################################## +load("../data/dataAges.rda") +source("../R/progClassic.R") + +publicA(1) +privateA(2) + diff --git a/main.R b/main.R new file mode 100755 index 0000000..334c8a7 --- /dev/null +++ b/main.R @@ -0,0 +1,5 @@ +########################################## +### Nom du programme : main.R ### +########################################## +source("../testsDev/testsProgClassic.R") + diff --git a/man/dataAges.Rd b/man/dataAges.Rd index e18fe3d..7b0b2ac 100755 --- a/man/dataAges.Rd +++ b/man/dataAges.Rd @@ -35,4 +35,6 @@ str(dataAges) } \keyword{datasets} +\keyword{documentation} + diff --git a/man/packClassic-package.Rd b/man/packClassic-package.Rd index 23c00e7..8689e97 100755 --- a/man/packClassic-package.Rd +++ b/man/packClassic-package.Rd @@ -16,8 +16,8 @@ \tabular{ll}{ Package: \tab packClassic\cr Type: \tab Package\cr - Version: \tab 0.5.1\cr - Date: \tab 2009-05-23\cr + Version: \tab 0.5.2\cr + Date: \tab 2009-10-15\cr License: \tab GPL(>=2.0)\cr LazyLoad: \tab yes\cr } @@ -44,4 +44,6 @@ publicC(3) } \keyword{package} +\keyword{documentation} + diff --git a/tests/testsProgClassicRCoreTeam.R b/tests/testsProgClassicRCoreTeam.R new file mode 100755 index 0000000..fd18965 --- /dev/null +++ b/tests/testsProgClassicRCoreTeam.R @@ -0,0 +1,10 @@ +########################################## +### Nom du programme : testClassique.R ### +########################################## +library(packClassic) +data(dataAges) + +publicA(1) +.publicB(3) +publicC(5) +publicC(dataAges$age) diff --git a/testsDev/testsProgClassic.R b/testsDev/testsProgClassic.R index 8ceb819..02098f6 100755 --- a/testsDev/testsProgClassic.R +++ b/testsDev/testsProgClassic.R @@ -1,12 +1,12 @@ ################################################################# -###testProgClassique.R### +### testProgClassique.R ### ################################################################# load("../data/dataAges.rda") source("../R/progClassic.R") -print(publicA(1)) -(privateA(2)) -(.publicB(3)) -(.privateB(4)) -(publicC(5)) -(publicC(dataAges$age)) -(privateC(6)) +publicA(1) +privateA(2) +.publicB(3) +.privateB(4) +publicC(5) +publicC(dataAges$age) +privateC(6)