How to perform shuffle on a list of words?
<p>I want to do a shuffle on a list of words in R, either using <code>permute::shuffle/shuffleSet()</code> or any other function.</p>

<p>Code:</p>

<pre><code>require(permute)
a &lt;- c("Ar","Ba","Bl","Bu","Ca")
x &lt;- list(a)
x
shuffleSet(x)
shuffle(x)
</code></pre>

<p>But when I try this code I get the error</p>

<pre><code>shuffleSet : Error in seq_len(n) : argument must be coercible to non-negative integer

shuffle : Error in factor(rep(1, n)) : 
  (list) object cannot be coerced to type 'integer'
</code></pre>

<p>Should <code>permute::shuffle/shuffleSet()</code> only be used only for integers? How do I perform a shuffle for the above list? Is there any other function to do this?</p>