HashTable-class: Hashtable Class

HashTable-classR Documentation

Hashtable Class

Description

Creates a hashtable-like object so as to represent data with a key structure (for example addon tables, rating-based factors etc). Also, it includes methods for populating the object via a .csv file and finding a value based on a specific key on an interval of keys For examples of the format of the CSVs files, please view RatingsMapping.csv or AddonTable.csv on the extdata folder in the installation folder of the library

Arguments

keys

A vector of keys

values

A vector of values mapping to the keys

keys_type

The type of the keys

values_type

The type of the values

Value

An object of type HashTable

Author(s)

Tasos Grivas <tasos@openriskcalculator.com>

Examples


## loading a ratings' mapping matrix from the extdata folder
rating_table = HashTable('RatingsMapping.csv',"character","numeric")
reg_weight =rating_table$FindValue("AAA")


sa-ccr/Trading documentation built on Feb. 23, 2024, 9:26 p.m.