permutations (version 1.0-0)

nullperm: Null permutations

Description

Null permutations are the equivalent of NULL

Usage

nullperm nullcycle nullword

Arguments

Format

Object nullperm is a zero-row matrix, coerced to word, specifically word(matrix(integer(0),0,0)) Object nullcycle is an empty list coerced to class cycle, specfically cycle(list())

Details

These objects are here to deal with the case where a length-zero permutation is extracted. The behaviour of these null objects is not entirely consistent.

Examples

Run this code

rperm(10,4)[0]  # null word

as.cycle(1:5)[0]  # null cycle


c(NULL,megaminx)      # probably not what the user intended...
c(nullcycle,megaminx) # more useful.

Run the code above in your browser using DataCamp Workspace