Learn R Programming

move (version 1.1.424)

subset-method: Returns a single object from a MoveStack

Description

The subset function can be used to return a single Move object from a MoveStack object.

Usage

## S3 method for class 'MoveStack,ANY,ANY':
[(x,i)
  ## S3 method for class 'MoveStack,character,missing':
[[(x,i)

Arguments

x
MoveStack object
i
numeric, number of position in the stack

Details

The double square bracket method is used for sub setting a stack to a single move object according to the individual name.

Examples

Run this code
load(system.file("extdata", "move.RData", package="move"), .GlobalEnv)
st <- moveStack(list(leroy,ricky=ricky))
st[1]
st[['ricky']]

Run the code above in your browser using DataLab