For matrices, 2-dim tables and data frames, head()
(tail()
) returns
the first (last) n
rows and m
columns when n > 0
or all but the
last (first) n
rows when n < 0
(with similar behavior
for m
).
tail()
will add row and column names of
the form "[n,]"
and "[,n]"
to the result, so that it looks similar to the
last lines and columns of x
when printed. Setting addrownums =
FALSE
suppresses this behaviour.
A method for spam.chol.NgPeyton
objects is
exported as well.