corner: corner, an improved head()

View source: R/corner.R

cornerR Documentation

corner, an improved head()

Description

Returns the first part of an object similar to head() but subsets columns as well as rows, and also handles lists of objects.

Usage

corner(mat, n = 6)

Arguments

mat

A DataFrame, data.frame, GRanges, matrix, tibble, or list

n

Integer number of rows and columns you want returned

Value

An n x n object of the original class (or a list of n nxn objects)

Author(s)

Emily E. Burke

Examples


m <- matrix(rnorm(1000), ncol = 10)
corner(m)

lis <- list(iris, mtcars, matrix(rnorm(1000), ncol = 10))
corner(lis)

LieberInstitute/jaffelab documentation built on April 1, 2024, 7:26 a.m.