View source: R/mlbench-class.R
mlbench.xor | R Documentation |
The inputs of the XOR problem are uniformly distributed on
the d
-dimensional cube with corners \{\pm 1\}
. Each pair of
opposite corners form one class, hence the total number of classes is
2^(d-1)
mlbench.xor(n, d=2)
n |
number of patterns to create |
d |
dimension of the XOR problem |
Returns an object of class "mlbench.xor"
with components
x |
input values |
classes |
factor vector of length |
# 2d example
p<-mlbench.xor(300,2)
plot(p)
#
# 3d example
p<-mlbench.xor(300,3)
plot(p)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.