Learn R Programming

set6 (version 0.1.1)

strprint: String Representation For Print

Description

Parsable object to be supplied to print, data.frame, etc.

Arguments

object

R6 object

n

Number of elements to display before & after ellipsis

Value

String representation of the set.

R6 Usage

$strprint(object, n = 2)

Details

strprint is a suggested method that should be included in all R6 classes to be passed to methods such as cat, summary and print.

It is often not required to call this directly; the print method is recommended for printing strings to the console.

Examples

Run this code
# NOT RUN {
Set$new(1:10)$strprint(n = 2)
Set$new(1:10)$strprint()
# }

Run the code above in your browser using DataLab