condensed: Condensed: an S3 class for condensed summaries.

Description Usage Arguments S3 methods Examples

View source: R/condensed.r

Description

This object managed the properties of condensed (summarised) data frames.

Usage

1
2
3
4
5
condensed(groups, grouped, summary)

is.condensed(x)

as.condensed(x)

Arguments

groups

list of bined objects

grouped,summary

output from C++ condense function

x

object to test or coerce

S3 methods

Mathematical functions with methods for binsum object will modify the x column of the data frame and rebin the data, calculating updated summary statistics.

Currently methods are provided for the Math group generic, logical comparison and arithmetic operators, and round_any.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
if (require("ggplot2")) {

x <- rchallenge(1e4)
xsum <- condense(bin(x, 1 / 10))

# Basic math operations just modify the first column
autoplot(xsum)
autoplot(xsum * 10)
autoplot(xsum - 30)
autoplot(abs(xsum - 30))

# Similarly, logical operations work on the first col
autoplot(xsum[xsum > 10, ])
}

hadley/bigvis documentation built on May 17, 2019, 9:45 a.m.