class_docstr: Converts featuresets and labeled featuresets to ARFF-formatted
  strings, appropriate for input into Weka.
  
  Features and classes can be specified manually in the constructor, or may
  be determined from data using ``from_train``.
docstr: Returns the ARFF data section for the given data.
  
  :param tokens: a list of featuresets (dicts) or labelled featuresets
      which are tuples (featureset, label).
  :param labeled: Indicates whether the given tokens are labeled
      or not.  If None, then the tokens will be assumed to be
      labeled if the first token's value is a tuple or list.
docstr_tok: ["Returns","the","ARFF","data","section","for","the","given","data",".",":","param","tokens",":","a","list","of","featuresets","(","dicts",")","or","labelled","featuresets","which","are","tuples","(","featureset",",","label",")",".",":","param","labeled",":","Indicates","whether","the","given","tokens","are","labeled","or","not",".","If","None",",","then","the","tokens","will","be","assumed","to","be","labeled","if","the","first","token","'s","value","is","a","tuple","or","list","."]
code: def data_section(self, tokens, labeled=None):
      """
      Returns the ARFF data section for the given data.
  
      :param tokens: a list of featuresets (dicts) or labelled featuresets
          which are tuples (featureset, label).
      :param labeled: Indicates whether the given tokens are labeled
          or not.  If None, then the tokens will be assumed to be
          labeled if the first token's value is a tuple or list.
      """
      # Check if the tokens are labeled or unlabeled.  If unlabeled,
      # then use 'None'
      if labeled is None:
          labeled = tokens and isinstance(tokens[0], (tuple, list))
      if not labeled:
          tokens = [(tok, None) for tok in tokens]
  
      # Data section
      s = "\n@DATA\n"
      for tok, label in tokens:
          for fname, ftype in self._features:
              s += "%s," % self._fmt_arff_val(tok.get(fname))
          s += "%s\n" % self._fmt_arff_val(label)
  
      return s
  
imports: import os
  import re
  import subprocess
  import tempfile
  import time
  import zipfile
  from sys import stdin
  from nltk.classify.api import ClassifierI
  from nltk.internals import config_java, java
  from nltk.probability import DictionaryProbDist
label_desc: Use image node_id 7 for calling the ARFF_Formatter obj's underlying member method code with example usage: obj.data_section(tokens, labeled) and returns: s