Recursive run length encoding bottom up.

Description

Encode a matrix as run-length, bottom up. Encoding respects previous runs, e.g line n-1 encodes rns in each run of line n.

May be removed.

Usage

1
rrleb(x)

Arguments

x

a matrix.

Value

list of run length encoded lines

Author(s)

G√ľnther Sawitzki <gsawitzki@users.r-forge.r-project.org>

See Also

rle,

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
x <- matrix(c(
	3,3,4,4,4,
	 5,5,6,6,7,
	 8,9,9,0,0,
	 1,1,1,2,2

 ),nrow=4, ncol =5, byrow=TRUE)
 xrrleb <- rrleb(x)
 xrrleb

 t(sapply(xrrleb, inverse.rle))

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