Show the head and tail of an object

Share:

Description

Show both the head and tail of an R object

Usage

1
ht(x, n = 6L, m = n, returnList = FALSE, ...)

Arguments

x

The object to show

n

The number of elements to list for the head

m

The number of elements to list for the tail

returnList

Logical. Should the result be returned as a list

...

additional arguments passed to functions (not used at the moment)

Details

This function does no error checking and it is up to the user to ensure that the input is indeed symmetric, positive-definite, and a matrix.

Value

NULL unless returnList is set to TRUE in which case a list is returned

Author(s)

Claus Ekstrom, claus@rprimer.dk.

Examples

1
2
3
4
ht(trees)
ht(diag(20))
ht(1:20)
ht(1:20, returnList=TRUE)

Want to suggest features or report bugs for rdrr.io? Use the GitHub issue tracker.