Learn R Programming

HistDat (version 0.2.0)

c,HistDat-method: Concatenate observations into this instance

Description

Concatenate observations into this instance

Usage

# S4 method for HistDatCompatible
c(x, ...)

Arguments

x

The first value to concatenate

...

The remaining values to concatenate

Value

A new HistDat object, with the other numeric values integrated into it

Examples

Run this code
# NOT RUN {
hd <- HistDat(vals = 1:3, counts = c(1, 2, 1))
hd_2 = c(1, 1, hd)
hd@counts # returns 1 2 1
hd_2@counts # returns 3 2 1, as the first value now has 2 more counts
hd_2@vals # returns 1 2 3 (this is unchanged)
# }

Run the code above in your browser using DataLab