title: How to save dataframe to pickle file using Pyspark
body: <p>I have to save a dataframe to Pickle file, but it returns an error </p>
  
  <pre><code>df.saveAsPickleFile(path)
  </code></pre>
  
  <p><strong>AttributeError: 'Dataframe' object has no attribute 'saveAsPickleFile'</strong></p>