datadr (version 0.8.4)

updateAttributes: Update Attributes of a 'ddo' or 'ddf' Object

Description

Update attributes of a 'ddo' or 'ddf' object

Usage

updateAttributes(obj, control = NULL)

Arguments

obj
an object of class 'ddo' or 'ddf'
control
parameters specifying how the backend should handle things (most-likely parameters to rhwatch in RHIPE) - see rhipeControl

Value

  • an object of class 'ddo' or 'ddf'

Details

This function looks for missing attributes related to a ddo or ddf (distributed data object or data frame) object and runs MapReduce to update them. These attributes include "splitSizeDistn", "keys", "nDiv", "nRow", and "splitRowDistn". These attributes are useful for subsequent computations that might rely on them. The result is the input modified to reflect the updated attributes, and thus it should be used as obj <- updateAttributes(obj).

References

Bennett, Janine, et al. "Numerically stable, single-pass, parallel statistics algorithms.' Cluster Computing and Workshops", 2009. CLUSTER09. IEEE International Conference on. IEEE, 2009

See Also

ddo, ddf, divide

Examples

Run this code
d <- divide(iris, by = "Species")
# some attributes are missing:
d
summary(d)
d <- updateAttributes(d)
# now all attributes are available:
d
summary(d)

Run the code above in your browser using DataLab