title: What will be the scala equivalent of the following python code?
body: <pre><code>men = data.flatMap(lambda x :x['text'].split(" ")) \
  .filter(lambda x: len(x.strip()) &gt; 1) \
  .filter(lambda x : x[0] == '@') \
  .map(lambda x:x.replace('@','')) 
  </code></pre>
  
  <p>I tried but I'm unable to solve it.</p>
  
  <pre><code>var men=df.map((df.select("text"))
            .split(" ")).filter(x =&gt; (x.strip()).length()&gt;1)
            .filter(x=&gt;x(0)=="@")
            .map(x=&gt;x.replace("@",""))
  </code></pre>
  
  <blockquote>
    <p>:35: error: value split is not a member of org.apache.spark.sql.DataFrame</p>
  </blockquote>
  
  <p>here df is my DataFrame, text is the name of the column that I'm working on.</p>