title: Basic lzw compression help in python
body: <p>I'm just trying to write a really basic script that'll take some input text and compress it with lzw, using this package: <a href="http://packages.python.org/lzw/" rel="nofollow">http://packages.python.org/lzw/</a></p>
  
  <p>I've never tried any encoding with python before and am thoroughly confused =( - I also can't find any documentation online about it, other than the package info.</p>
  
  <p>Here's what I have:</p>
  
  <pre><code>import lzw
  
  file = lzw.readbytes("collectemailinfo.txt", buffersize=1024)
  enc = lzw.compress(file)
  print enc
  </code></pre>
  
  <p>Any help or pointers of any kind would be much appreciated!</p>
  
  <p>Thanks =)</p>