rstack v1.0.0

0

Monthly downloads

0th

Percentile

Stack Data Type as an 'R6' Class

An extremely simple stack data type, implemented with 'R6' classes. The size of the stack increases as needed, and the amortized time complexity is O(1). The stack may contain arbitrary objects.

Readme

rstack

Stack data type as an 'R6' class

Project Status: Active - The project has reached a stable, usable state and is being actively developed. Linux Build Status Windows Build status CRAN RStudio mirror downloads Coverage Status

An extremely simple stack data type, implemented with 'R6' classes. The size of the stack increases as needed, and the amortized time complexity is O(1). The stack may contain arbitrary objects.

Installation

source("https://install-github.me/MangoTheCat/rstack")

Usage

library(rstack)
S <- stack$new()
S$push(1L)
S$peek()
#> [1] 1
S$pop()
#> [1] 1
S$size()
#> [1] 0
S$push(NULL)
S$push(iris)
colnames(S$pop())
#> [1] "Sepal.Length" "Sepal.Width"  "Petal.Length" "Petal.Width" 
#> [5] "Species"
S$peek()
#> NULL

License

MIT © Mango Solutions

Functions in rstack

Name Description
stack A stack data type, implemented as an R6 class
No Results!

Last month downloads

Details

License MIT + file LICENSE
LazyData true
URL https://github.com/MangoTheCat/rstack#readme
BugReports https://github.com/MangoTheCat/rstack/issues
RoxygenNote 5.0.1
Encoding UTF-8
NeedsCompilation no
Packaged 2016-08-02 08:01:09 UTC; gaborcsardi
Repository CRAN
Date/Publication 2016-08-02 13:05:28
suggests covr , testthat
imports R6
Contributors Gabor Csardi

Include our badge in your README

[![Rdoc](http://www.rdocumentation.org/badges/version/rstack)](http://www.rdocumentation.org/packages/rstack)