title: sorting rows according to a row pattern
body: <p>I want to re-arrange the rows of a dataframe that looks like this: </p>
  
  <pre><code>qs=c("q11", "q22", "q2", "q6", "q10")
  ans=rep(1,times=length(qs))
  df=data.frame(qs,ans)
  arrange(df,qs)
  
   qs ans
  1 q10   1
  2 q11   1
  3  q2   1
  4 q22   1
  5  q6   1
  </code></pre>
  
  <p>However, I want the sorting of the rows to look in the much more logical order, such as this:</p>
  
  <pre><code> qs ans
  1  q2   1
  2  q6   1
  3 q10   1
  4 q11   1
  5 q22   1
  </code></pre>
  
  <p>Can someone help me with this ? </p>