I'm new to AI and ML.
I am attempting to write code that will generate a decision tree given a random set of integers 0 - 9 as opposed to giving the code the choice between 0 and 1. Ideally, the code will output the likelihood (probability) of a pair of any two integers between 0 - 9.
the code is as follows:
from sklearn import tree
import random
num1 = random.randint (0, 9)
num2 = random.randint (0, 9)
X = [[num1, num1], [num2, num2]]
Y = [num1, num2]
clf = tree.DecisionTreeClassifier()
clf = clf.fit(X, Y)
the program still outputs a decision tree from set of [0,1] and not random integers between 0 - 9.
what am i doing wrong?
import random