Description Usage Arguments Details Examples
View source: R/HSC_PC_Binning.R
Extends the HSC_PC abstract class.
1 | HSC_PC_Binning(min_value, max_value, bins, value_field)
|
min_value |
(numeric) - Minimal value. |
max_value |
(numeric) - Maximal value: |
bins |
(integer) - A number of bins that needs to be created. |
value_field |
(character) - The name of the value field in the input event stream. |
A pre-classifier takes performs binning on a value field of the input event stream.
1 2 3 4 5 6 | event_stream <- data.frame(product=c("P45","P134","P45","P134","P134","P45","P134"),
sales=c(2,12,18,16,18,24,8),
alert=c(NA,NA,NA,NA,NA,"Alert P45","Alert P134"))
pc <- HSC_PC_Binning(0,100,40,"sales")
cons_stream <- classify(pc,event_stream)
# Minimal value = 0, Maximal value = 100, 40 bins, values taken from the field named *sales*
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.