\title{Consumer class to down-sample data}

  A \code{\linkS4class{Consumer}}-class to select records with fixed
  probability, returning a yield of fixed size. Successive calls to
  \code{yield} result in sampling of subsequent records in the stream,
  until the stream is exhausted.


Downsample(probability=0.1, sampledSize=1e6, ...)


  \item{probability}{A \code{numeric(1)} between 0, 1 indicating the
    probability with which a record should be retained.}

  \item{...}{Additional arguments, passed to the \code{$new} method of
    the underlying reference class. Currently unused.}

  \item{sampledSize}{A \code{integer(1)} indicating the number of
    records to return.}

\section{Methods}{See \code{\link{Consumer}} Methods.}

\section{Internal Class Fields and Methods}{

  Internal fields of this class are are described with, e.g.,

  Internal methods of this class are described with
  \code{getRefClass("Downsample")$methods()} and


\author{Martin Morgan \url{mtmorgan@fhcrc.org}}