I’m new to Mathematica and just wanted to try out the Classify function by trying to classify Swedish male vs female names. It turns out it doesn’t even look at the training data; the classification is performed solely on the basis of the number of pieces training data of each type. My code:
femaleNames = {"Amanda", "Anna", "Emma", "Erika", "Elin", "Hanna",
"Karin", "Marie", "Sara", "Viola"};
maleNames = {"Anders", "Bo", "Erik", "Göran", "Jakob", "Martin",
"Knut", "Sune", "Tim", "Örjan"};
trainingData =
Join[Table[name -> True, {name, femaleNames}],
Table[name -> False, {name, maleNames}]];
c = Classify[trainingData];
c["Daniel", "Probabilities"]
<|False -> 0.5, True -> 0.5|>
The last row shows the probabilities is 0.5 since I have the same number of names of each class. If I change the size of e.g. the femaleNames set, the probabilites changes accordingly. I tried the various classification methods and they all fail in the same way.
What am I missing?