dataf.growth: Berkeley Growth Study Data

Description Usage Format Details Source See Also Examples

View source: R/dataf.growth.r

Description

The data set contains the heights of 39 boys and 54 girls from age 1 to 18 and the ages at which they were collected.

Usage

1

Format

The functional data as a data structure.

dataf

The functional data as a list of objects. Each object is characterized by two coordinates

args

age - a numeric vector of length 31 giving the ages at which the heights were measured

vals

height - a numeric vector of heights in centimeters of 39 boys and 54 girls

labels

The classes of the objects: boy, girl

Details

The ages are not equally spaced.

Source

Ramsay, James O., and Silverman, Bernard W. (2006), Functional Data Analysis, 2nd ed., Springer, New York.

Ramsay, James O., and Silverman, Bernard W. (2002), Applied Functional Data Analysis, Springer, New York, ch. 6.

Tuddenham, R. D., and Snyder, M. M. (1954) "Physical growth of California boys and girls from birth to age 18", University of California Publications in Child Development, 1, 183-364.

See Also

dataf.* for other functional data sets

plot.functional for building plots of functional data

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
## load the Growth dataset
dataf = dataf.growth()

## view the classes
unique(dataf$labels)

## access the 5th point of the 2nd object
dataf$dataf[[2]]$args[5]
dataf$dataf[[2]]$vals[5]

## plot the data
## Not run: 
  labels = unlist(dataf$labels)
  plot(dataf, 
    main = paste("Growth: girls red (", sum(labels == "girl"), "),", 
                      " boys blue (", sum(labels == "boy"), ")", sep=""),
    xlab="Year", ylab="Height, cm",
    colors = c("blue", "red")   # in alphabetical order of class labels   
    )

## End(Not run)

Example output

Loading required package: MASS
Loading required package: class
Loading required package: robustbase
[[1]]
[1] "girl"

[[2]]
[1] "boy"

[1] 2
 2 
90 

ddalpha documentation built on Jan. 9, 2020, 5:09 p.m.