title: pandas: write empty DataFrame to HDF file
body: <p>Is there a way to force pandas to write an empty DataFrame to an HDF file?</p>
  
  <pre class="lang-py prettyprint-override"><code>import pandas as pd
  df = pd.DataFrame(columns=['x','y'])
  df.to_hdf('temp.h5', 'xxx')
  df2 = pd.read_hdf('temp.h5', 'xxx') 
  </code></pre>
  
  <p>Output:</p>
  
  <pre class="lang-none prettyprint-override"><code>Traceback (most recent call last):
    File "&lt;stdin&gt;", line 1, in &lt;module&gt;
    File ".../Python-3.6.3/lib/python3.6/site-packages/pandas/io/pytables.py", line 389, in read_hdf
      return store.select(key, auto_close=auto_close, **kwargs)
    File ".../Python-3.6.3/lib/python3.6/site-packages/pandas/io/pytables.py", line 740, in select
      return it.get_result()
    File ".../Python-3.6.3/lib/python3.6/site-packages/pandas/io/pytables.py", line 1518, in get_result
      results = self.func(self.start, self.stop, where)
    File ".../Python-3.6.3/lib/python3.6/site-packages/pandas/io/pytables.py", line 733, in func
      columns=columns)
    File ".../Python-3.6.3/lib/python3.6/site-packages/pandas/io/pytables.py", line 2986, in read
      idx=i), start=_start, stop=_stop)
    File ".../Python-3.6.3/lib/python3.6/site-packages/pandas/io/pytables.py", line 2575, in read_index
      _, index = self.read_index_node(getattr(self.group, key), **kwargs)
    File ".../Python-3.6.3/lib/python3.6/site-packages/pandas/io/pytables.py", line 2676, in read_index_node
      data = node[start:stop]
    File ".../Python-3.6.3/lib/python3.6/site-packages/tables/vlarray.py", line 675, in __getitem__
      return self.read(start, stop, step)
    File ".../Python-3.6.3/lib/python3.6/site-packages/tables/vlarray.py", line 811, in read
      listarr = self._read_array(start, stop, step)
    File "tables/hdf5extension.pyx", line 2106, in tables.hdf5extension.VLArray._read_array (tables/hdf5extension.c:24649)
  ValueError: cannot set WRITEABLE flag to True of this array
  </code></pre>
  
  <p>Writing with <code>format='table'</code>:</p>
  
  <pre class="lang-py prettyprint-override"><code>import pandas as pd
  df = pd.DataFrame(columns=['x','y'])
  df.to_hdf('temp.h5', 'xxx', format='table')
  df2 = pd.read_hdf('temp.h5', 'xxx')
  </code></pre>
  
  <p>Output:</p>
  
  <pre class="lang-none prettyprint-override"><code>Traceback (most recent call last):
    File "&lt;stdin&gt;", line 1, in &lt;module&gt;
    File ".../Python-3.6.3/lib/python3.6/site-packages/pandas/io/pytables.py", line 389, in read_hdf
      return store.select(key, auto_close=auto_close, **kwargs)
    File ".../Python-3.6.3/lib/python3.6/site-packages/pandas/io/pytables.py", line 722, in select
      raise KeyError('No object named {key} in the file'.format(key=key))
  KeyError: 'No object named xxx in the file'
  </code></pre>
  
  <p>Pandas version: 0.24.2</p>
  
  <p>Thank you for your help!</p>