title: Orange Data Table with specific domain
body: <p>I’m trying to create an Orange Data Table from a csv-file. To achieve this I'm currently trying to do this using the following steps:</p>
  
  <ol>
  <li>Create the target domain </li>
  <li>Reading the file to a temporary data table</li>
  <li>Creating a new data table using the data in the temp table and the
  target domain</li>
  </ol>
  
  <p>Changing the csv to a tab-file with a three line header (<a href="https://docs.orange.biolab.si/3/data-mining-library/reference/data.io.html" rel="nofollow noreferrer">https://docs.orange.biolab.si/3/data-mining-library/reference/data.io.html</a>) is not an option.</p>
  
  <p>When translating this procedure to code I get the following:</p>
  
  <pre><code>  from Orange.data import Domain, DiscreteVariable, ContinuousVariable, Table
  
      # Creating specific domain. Two attributes and a Class variable used as target
      target_domain = Domain([ContinuousVariable.make("Attribute 1"),ContinuousVariable.make("Attribute 2")],DiscreteVariable.make("Class"))
      print('Target domain:',target_domain) 
      # Target domain: [Attribute 1, Attribute 2 | Class]
  
      # Reading in the file
      test_data = Table.from_file('../data/knn_trainingset_example.csv')
      print('Domain from file:',test_data.domain)
      # Domain from file: [Attribute 1, Attribute 2, Class]
  
      # Using specific domain with test_data
      final_data = Table.from_table(target_domain,test_data)
  
      print('Domain:',final_data.domain)
      print('Data:')
      print(final_data)
      # Domain: [Attribute 1, Attribute 2 | Class]
      # Data:
      # [[0.800, 6.300 | ?],
      #  [1.400, 8.100 | ?],
      #  [2.100, 7.400 | ?],
      #  [2.600, 14.300 | ?],
      #  [6.800, 12.600 | ?],
      #  [8.800, 9.800 | ?],
      # ...
  </code></pre>
  
  <p>As you can see from the final print statement the class variable is unknown (?) instead of the expected class (+ or -). </p>
  
  <p>Can someone explain/solve this behavior? Provide a better/different way to create a Data Table with a specific domain?</p>