InformationTable: R6 class representing an information table.

Description Details Public fields Methods

Description

An information table consists of the decision table and meta-data.

Details

This class stores the decision table, and meta-data. The decision table consists of an object identifier column, a decision column, and at least one additional attribute. The meta-data consist of the attribute names, their types, and the alpha and beta values for similarity attributes.

Public fields

decisionTable

the set of examples

metaData

meta-data of the attributes, including their name and type, along with alpha and beta parameters for similarity variables

objects

vector of object names

Methods

Public methods


Method new()

Create a new information table object.

Usage
InformationTable$new(decisionTable, metaData = NA)
Arguments
decisionTable

data frame containing the decision examples

metaData

data frame containing the meta-data of the attributes. This parameter is optional, and if not provided, we assume all dominance attributes.


Method isCompatible()

Method to determine whether another information table is compatible with this one.

Usage
InformationTable$isCompatible(it)
Arguments
it

the information table to compare to


Method getType()

Method to get the type of an attribute.

Usage
InformationTable$getType(attribute)
Arguments
attribute

the name of the attribute

Returns

the type


Method removeObjects()

Method for creating a new information table by removing examples of belonging to the specified objects.

Usage
InformationTable$removeObjects(objects)
Arguments
objects

the object to filter out

Returns

a new information table instance


Method downwardClassUnion()

Method for calculating the downward class union.

Usage
InformationTable$downwardClassUnion(class)
Arguments
class

the decision class to compare to

Returns

the set of objects in the downward class union


Method upwardClassUnion()

Method for calculating the upward class union.

Usage
InformationTable$upwardClassUnion(class)
Arguments
class

the decision class to compare to

Returns

the set of objects in the upward class union


Method encodeDecisionColumn()

Method for encoding the decision column to the 1:N range, where N is the cardinality of this column.

Usage
InformationTable$encodeDecisionColumn()
Returns

the encoded decision column


Method decodeDecisions()

Method for decoding 1:N-encoded decisions.

Usage
InformationTable$decodeDecisions(encoded)
Arguments
encoded

a vector of encoded decisions

Returns

a vector with the decoded decisions


Method classUnions()

Method for calculating all downward- and upward class unions at once.

Usage
InformationTable$classUnions()
Returns

a pair of matrices for both class unions, where each row represents a class, and each column represents an object


Method partitionAttributes()

Method that partitions attribute set P into into sets of the same attribute type. Only types relevant for the dominance relation are considered (indiscernibility, similarity, and dominance).

Usage
InformationTable$partitionAttributes(P)
Arguments
P

the set of attributes to partition - vector of attribute names

Returns

a list of attribute sets Function to determine whether x dominates y on the mixed attribute set P.


Method dominates()

Usage
InformationTable$dominates(x, y, P, compareSimilaritySwitched = FALSE)
Arguments
x

the left operand - object name

y

the right operand - object name

P

the set of attributes to test - vector of attribute names

compareSimilaritySwitched

whether to test similarity with the parameters switched

Returns

whether x dominates y on attribute set P


Method dominatingAndDominatedSets()

Method for calculating the P-dominated and P-dominating sets all at once.

Usage
InformationTable$dominatingAndDominatedSets(P)
Arguments
P

the set of attributes to test - vector of attribute names Method to determine whether x is similar to y on attribute q.


Method similar()

Usage
InformationTable$similar(x, y, q)
Arguments
x

the left operand - a data frame

y

the right operand - a data frame

q

the attribute to test

Returns

whether x is similar to y on attribute q


Method dominatingSet()

This method calculates the dominating set of an object with respect to a criterion set.

Usage
InformationTable$dominatingSet(x, P, compareSimilaritySwitched = TRUE)
Arguments
x

the object - object name

P

the criterion set

compareSimilaritySwitched

whether to test similarity with the parameters switched

Returns

the set of objects that dominate object x


Method dominatedSet()

This method calculates the dominated set of an object with respect to a criterion set.

Usage
InformationTable$dominatedSet(x, P, compareSimilaritySwitched = FALSE)
Arguments
x

the object - object name

P

the criterion set

compareSimilaritySwitched

whether to test similarity with the parameters switched

Returns

the set of objects that are dominated by object x


Method upwardClassUnionUpperApproximation()

This method calculates the P-upper approximations of the upward class unions.

Usage
InformationTable$upwardClassUnionUpperApproximation(dominating_U)
Arguments
dominating_U

the P-dominating sets (U) - matrix

Returns

the approximations for all classes in a boolean matrix from


Method upwardClassUnionLowerApproximation()

This method calculates the P-lower approximations of the upward class unions.

Usage
InformationTable$upwardClassUnionLowerApproximation(downward_U)
Arguments
downward_U

the P-upper approximations of the downward class unions - matrix

Returns

the approximations for all classes in a boolean matrix from


Method downwardClassUnionUpperApproximation()

This method calculates the P-upper approximations of the downward class unions.

Usage
InformationTable$downwardClassUnionUpperApproximation(dominated_U)
Arguments
dominated_U

the P-dominated sets (U) - matrix

Returns

the approximations for all classes in a boolean matrix from


Method downwardClassUnionLowerApproximation()

This method calculates the P-lower approximations of the downward class unions.

Usage
InformationTable$downwardClassUnionLowerApproximation(upward_U)
Arguments
upward_U

the P-upper approximations of the upward class unions - matrix

Returns

the approximations for all classes in a boolean matrix from


Method roughSets()

This method calculates the P-lower and P-upper approximations of class unions and boundary regions.

Usage
InformationTable$roughSets(P)
Arguments
P

the attribute set

Returns

a named list of the approximations


Method boundaryRegions()

This method calculates the boundary regions of rough sets.

Usage
InformationTable$boundaryRegions(roughSets)
Arguments
roughSets

the class union approximations.

Returns

the upward and downward boundary regions


Method accuracyOfApproximation()

This method calculates the accuracy of the approximations of the class unions.

Usage
InformationTable$accuracyOfApproximation(roughSets)
Arguments
roughSets

the approximations

Returns

a pair of vectors describing the accuracy of the downward and upward class union approximations


Method qualityOfApproximation()

This method calculates the quality of the approximations of the class unions.

Usage
InformationTable$qualityOfApproximation(boundaryRegions)
Arguments
boundaryRegions

the boundary regions of the rough set

Returns

a number expressing the ratio of all P-correctly sorted actions to all actions in the decision table


Method clone()

The objects of this class are cloneable with this method.

Usage
InformationTable$clone(deep = FALSE)
Arguments
deep

Whether to make a deep clone.


jaspeir/NIJ_Tabitha documentation built on June 3, 2020, 12:38 a.m.