Zelig uses only three of R's many data structures:
- A variable is a one-dimensional vector of length
.
- A data frame is a rectangular matrix with
rows and
columns. Each column represents a variable and each row an
observation. Each variable may have a different class. (See
Section
for a list of classes.) You may refer to
specific variables from a data frame using, for example, data$variable.
- A list is a combination of different data structures. For
example, z.out contains both coefficients (a vector) and
data (a data frame). Use names() to view the elements
available within a list, and the $ operator to refer to an
element in a list.
For a more comprehensive introduction, including ways to manipulate
these data structures, please refer to Chapter
.
Gary King
2007-06-01