HSC_PP: Pre-processor top-level class

Description Usage Arguments Details

View source: R/HSC_PreProcessor.R

Description

Class that needs to be derived to create new pre-processors. A pre-processor can be directly instantiated from the HSC_PP class.

Usage

1
2
HSC_PP(fields, timestamp_field, create_unique_key = FALSE,
  auto_id = FALSE)

Arguments

fields

(vector) - The complete list of fields in the input data streams that needs to be present in the output event stream

timestamp_field

(character) - The name of the sequencing field. Could be autogenerated by the pre-processor, or already present in the input data streams. Used for ordering of the output event stream.

create_unique_key

(logical) - If TRUE, the pre-processor adds field named .key to the output event stream comprising a unique key (1) for all data items.

auto_id

(logical) - If TRUE, the pre-processor generates autoincremented values and assigns then to the timestamp_field. Can be used when input data streams do not comprise any timing information.

Details

Example 1
pp <- HSC_PP(c("product","time","sales"),"time") - Creates a new HSC_PP pre-processor that uses time field for ordering of the output event stream.

Example 2
pp <- HSC_PP(c("product","sales"),"sequence_id",auto_id=TRUE) - Creates a new HSC_PP pre-processor that has no time field. Instead, the pre-processor adds the sequence_id field and generates autoincremented values for it.

Example 3
pp <- HSC_PP(c("sequence_val"),"sequence_id",create_unique_key=TRUE,auto_id=TRUE) - Creates a new HSC_PP pre-processor that has no time and no key field. The pre-processor adds the sequence_id field and generates autoincremented values for it. Also, the .key=1 column is added to all output events.


SeqDetect documentation built on March 2, 2020, 5:08 p.m.