Types

We'll work with may types in this package, including some abstract types that will be used to define the structure of our models.

VLDataScienceMachineLearningPackage.MySarcasmRecordCorpusModelType
MySarcasmRecordCorpusModel <: AbstractTextDocumentCorpusModel

Model for a collection of records in the Sarcasm dataset.

Fields

  • records::Dict{Int, MySarcasmRecordModel} - The records in the document (collection of records)
  • tokens::Dict{String, Int64} - A dictionary of tokens in alphabetical order (key: token, value: position) for the entire document
source
VLDataScienceMachineLearningPackage.MySMSSpamHamRecordCorpusModelType
MySMSSpamHamRecordCorpusModel <: AbstractTextDocumentCorpusModel

Model for a collection of records in the SMS Spam Ham dataset.

Fields

  • records::Dict{Int, MySMSSpamHamRecordModel} - The records in the document (collection of records)
  • tokens::Dict{String, Int64} - A dictionary of tokens in alphabetical order (key: token, value: position) for the entire document
source
VLDataScienceMachineLearningPackage.MyFullGeneralAdjacencyTreeType
mutable struct MyFullGeneralAdjacencyTree <: AbstractTreeModel

The MyFullGeneralAdjacencyTree type is a model of a full general adjacency tree that uses a dictionary to store the tree structure. There is a build and populate! method to build the tree and populate it with data.

Fields

  • data::Union{Nothing, Dict{Int64,NamedTuple}} - A dictionary that stores the node data for the tree.
  • connectivity::Dict{Int64,Array{Int64,1}} - A dictionary that stores the connectivity information between nodes.
  • h::Int64 - The height of the tree.
  • n::Int64 - The branching factor of the tree.
source
VLDataScienceMachineLearningPackage.MyAdjacencyRecombiningCommodityPriceTreeType
mutable struct  MyAdjacencyRecombiningCommodityPriceTree <: AbstractPriceTreeModel

The MyAdjacencyRecombiningCommodityPriceTree type is a model of a commodity price tree that uses an dictionary to store the price data. This model stores the connectivity information between nodes.

Fields

  • data::Union{Nothing, Dict{Int64,NamedTuple}} - A dictionary that stores the price data and path informationfor the tree.
  • connectivity::Dict{Int64,Array{Int64,1}} - A dictionary that stores the connectivity information between nodes.
source
VLDataScienceMachineLearningPackage.MyOneDimensionalElementaryWolframRuleModelType
mutable struct MyOneDimensionalElementaryWolframRuleModel <: AbstractRuleModel

The MyOneDimensionalElementarWolframRuleModel mutable struct represents a one-dimensional elementary Wolfram rule model.

Fields

  • index::Int - The index of the rule
  • radius::Int - The radius, i.e, the number of cells that influence the next state for this rule
  • rule::Dict{Int,Int} - A dictionary that holds the rule where the key is the binary representation of the neighborhood and the value is the next state
source
VLDataScienceMachineLearningPackage.MyGraphEdgeModelType
mutable struct MyGraphEdgeModel

A mutable edge model representing a directed or undirected connection between nodes. The model stores a numeric id, endpoint indices, and an optional numeric weight.

Fields

  • id::Int64 - Unique integer identifier for the edge.
  • source::Int64 - Identifier of the source node (or one endpoint).
  • target::Int64 - Identifier of the target node (or the other endpoint).
  • weight::Union{Nothing, Any} - Optional edge weight; nothing indicates an unweighted edge.
source
VLDataScienceMachineLearningPackage.MySimpleDirectedGraphModelType
mutable struct MySimpleDirectedGraphModel

A minimal mutable directed graph container that keeps node and edge registries and a children adjacency map for fast traversal of outgoing neighbors.

Fields

  • nodes::Union{Nothing, Dict{Int64, MyGraphNodeModel}} - Optional mapping from node id to MyGraphNodeModel. Use nothing when uninitialized.
  • edges::Union{Nothing, Dict{Tuple{Int, Int}, Int64}} - Optional mapping from (source, target) tuple to edge id. Use nothing when uninitialized.
  • children::Union{Nothing, Dict{Int64, Set{Int64}}} - Optional adjacency map from a node id to the set of its child (outgoing) node ids.
source
VLDataScienceMachineLearningPackage.MySimpleUndirectedGraphModelType
mutable struct MySimpleUndirectedGraphModel

A minimal mutable undirected graph container that keeps node and edge registries and a children adjacency map for fast traversal of outgoing neighbors.

Fields

  • nodes::Union{Nothing, Dict{Int64, MyGraphNodeModel}} - Optional mapping from node id to MyGraphNodeModel. Use nothing when uninitialized.
  • edges::Union{Nothing, Dict{Tuple{Int, Int}, Int64}} - Optional mapping from (source, target) tuple to edge id. Use nothing when uninitialized.
  • children::Union{Nothing, Dict{Int64, Set{Int64}}} - Optional adjacency map from a node id to the set of its child (outgoing) node ids.
source