headR Documentation

Return the First or Last part of an Object

Description

Returns the first or last parts of a FlashR vector or matrix.

Usage

## S4 method for signature 'fm'
head(x, n = 6L)

## S4 method for signature 'fm'
tail(x, n = 6L)

## S4 method for signature 'fmV'
head(x, n = 6L)

## S4 method for signature 'fmV'
tail(x, n = 6L)

Arguments

x

a FlashR vector or matrix.

n

a positive integer.

Value

An object (usually) like x but generally smaller.

Examples

mat <- fm.runif.matrix(100, 10)
head(mat)
tail(mat)