title: Python Training and Testing Error
body: <p>While I am trying to run the last bit of the following code, I get an error I am not able to figure out why. </p>
  
  <pre><code>import random
  combined_list = h_sub_text + s_sub_text
  print(len(combined_list))
  random.shuffle(combined_list)
  
  training_part = int(len(combined_list) * .7)
  print(len(combined_list))
  training_set = combined_list[:training_part]
  test_set =  combined_list[training_part:]
  print (len(train_set))
  print (len(test_set))
  
  import nltk.classify.util
  from nltk.classify import NaiveBayesClassifier
  
  classifier = NaiveBayesClassifier.train(train_set)
  
  accuracy = nltk.classify.util.accuracy(classifier, test_set)
  
  print("Accuracy is: ", accuracy * 100)
  </code></pre>
  
  <p>I get this error: </p>
  
  <pre><code>ValueError             Traceback (most recent call last)
  &lt;ipython-input-57-151936e75238&gt; in &lt;module&gt;()
    2 from nltk.classify import NaiveBayesClassifier
  
  ----&gt; 4 classifier = NaiveBayesClassifier.train(training_set)
  
    C:\Program Files (x86)\Anaconda3\lib\site-packages\nltk\classify\naivebayes.py in train(cls, labeled_featuresets, estimator)
  
  --&gt; 194         for featureset, label in labeled_featuresets:
  195             label_freqdist[label] += 1
  196             for fname, fval in featureset.items():
  
  ValueError: too many values to unpack (expected 2)
  </code></pre>
  
  <p>Thanks in advance.</p>