Print an Object with Attributes

DESCRIPTION:

Uses the attributes of an object to format the printing of the object.

USAGE:

print.structure(x, a=attributes(x), prefix="", ...) 

REQUIRED ARGUMENTS:

x
an object with attributes.

OPTIONAL ARGUMENTS:

a
list of attributes. Most of these will be printed after the body of the object.
prefix
character string to identify the attributes.
...
arguments passed to print methods for components of the list; most methods have additional arguments like digits to control how many digits of a number should be printed and quote to control whether or not quotes are put around character strings.

VALUE:

x, with the invisible flag set to prevent reprinting.

SIDE EFFECTS:

The function looks at the attributes of x and prints it as a matrix, array, or time series, if the appropriate attributes ( dim for the first two, or tsp for the third) are found. Other attributes are printed following the data in x. The print.default function calls print.structure if x has attributes.

DETAILS:

The prefix is printed with attributes to distinguish which object has the attribute in case of ambiguity.

SEE ALSO:

, .