# Classify command in Mathematica 10

Where can I find documentation about the methods used in the Classify command in Mathematica 10? Specifically, how does the method Markov work?

Any pointers to the documentation for the methods available in Classify, or an explanation of how the method Markov works, will be appreciated.

• Why don't you write to Wolfram Support and ask them about it? They're usually good at providing references, and references are usually more useful than guessing and reverse engineering. When you get a response, please post it here. – Szabolcs Jul 16 '14 at 17:29
• I can try that. Thanks. – Venkatramanan P.R. Jul 17 '14 at 3:58

Tried understanding the Markov method by extracting the properties using the ClassifierInformation command. I used the example given in the Mathematica 10 Documentation itself. At least for this example, it seems to be just a Naive Bayes classifier, with word tokenisation and converting to lowercase as the preprocessing steps. What I found is given below.

Note: I have changed the pictures of 'dog' and 'cat' (used in the Mathematica 10 documentation) to the words "DOG" and "CAT". I have given the Mathematica output (right below each command) wherever it was text.

c = Classify[{"the cat is grey" -> "CAT", "my cat is fast" -> "CAT", "this dog is scary" -> "DOG" , "the big dog" -> "DOG"}]

c[{"nice cat", "what a dog"}]


{"CAT", "DOG"}

ClassifierInformation[c]

ClassifierInformation[c, "MethodDescription"]


"The markov classifier of order 0 assumes that tokens are generated independently given the class and uses Bayes' theorem to predict the class. It is also called unigram model or naive bayes model."

ClassifierInformation[c, "Properties"]


{Classes, ClassNumber, ClassPriors, ExampleNumber, FeatureNames, FeatureNumber, FeaturePreprocessor, FeatureTypes, FunctionProperties, MethodDescription, Options, Properties, TokenNumber, Tokens, TrainingTime, IndeterminateThreshold, Method, UtilityFunction}

ClassifierInformation[c, "Options"]


{Method -> {"Markov", "AdditiveSmoothing" -> 1.}}

ClassifierInformation[c, "Tokens"]


{"the", "cat", "is", "grey", "my", "fast", "this", "dog", "scary", "big"}

ClassifierInformation[c, "ClassPriors"]


<|"CAT" -> 0.5, "DOG" -> 0.5|>

ClassifierInformation[c, "FeaturePreprocessor"]


ToLowerCase -> WordTokenize