Learn R Programming

HVT (version 24.9.1)

displayTable: Table for displaying summary

Description

This is the main function for displaying summary from model training and scoring

Usage

displayTable(
  data,
  columnName = NULL,
  value = NULL,
  tableType = "summary",
  scroll = FALSE,
  limit = 100
)

Value

A consolidated table of results from trainHVT and scoreHVT.

Arguments

data

List. A listed object from trainHVT or scoreHVT

columnName

Character. Name of the column that needs highlighting.

value

Numeric. The value above will be highlighted in red or green.

tableType

Character. Type of table to generate ('summary', 'compression' and 'metrics')

scroll

Logical. A value to have a scroll or not in the table.

limit

Numeric. A value to indicate how many rows to display. Applicable for summary tableType.

Author

Vishwavani <vishwavani@mu-sigma.com>, Alimpan Dey <alimpan.dey@mu-sigma.com>

See Also

trainHVT

Examples

Run this code
data <- datasets::EuStockMarkets
dataset <- as.data.frame(data)
#model training
hvt.results <- trainHVT(dataset, n_cells = 60, depth = 1, quant.err = 0.1,
                      distance_metric = "L1_Norm", error_metric = "max",
                      normalize = TRUE, quant_method = "kmeans", dim_reduction_method = 'sammon')
displayTable(data =  hvt.results$model_info$distance_measures, tableType = "metrics")
displayTable(data = hvt.results[[3]]$compression_summary,
columnName = 'percentOfCellsBelowQuantizationErrorThreshold', 
value = 0.8, tableType = "compression")
displayTable(data =hvt.results[[3]][['summary']], columnName= 'Quant.Error',
value = 0.1, tableType = "summary", scroll = TRUE)

Run the code above in your browser using DataLab