Creates a matrix of features and target based on the values from contingency matrix.

create_feature_target(n11, n01, n10, n00)

Arguments

n11

number of elements for which both target and feature equal 1.

n01

number of elements for which target and feature equal 1,0 respectively.

n10

number of elements for which target and feature equal 0,1 respectively.

n00

number of elements for which both target and feature equal 0.

Value

a matrix of 2 columns and n11+n10+n01+n00 rows. Columns represent target and feature vectors, respectively.

Examples

# equivalent of # target # feature 10 375 # 15 600 target_feature <- create_feature_target(10, 375, 15, 600)