<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On 17 February 2013 00:14, Jason Grout <span dir="ltr"><<a href="mailto:jason-sage@creativetrax.com" target="_blank">jason-sage@creativetrax.com</a>></span> wrote:<br>

<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div id=":1ur">Cool.  I didn't know that.  But if k was a list (for some other<br>
parameter), and you were trying to sub it in, you'd have to convert the<br>
list to a string, then convert it back in the decorator.  That's a<br>
little silly.</div></blockquote></div><br></div><div class="gmail_extra">In theory, but I don't think we've ever had such a case. The %%R magic has something roughly similar - you can pass in variables including arrays, like<br>

<br></div><div class="gmail_extra">%%R -i myvar<br></div><div class="gmail_extra">code...<br><br></div><div class="gmail_extra">In that case, the magic looks in the namespaces for 'myvar', so it doesn't have to be converted to a string and back. Arguably you could pull the variable in more elegantly with your proposal, something like:<br>

<br></div><div class="gmail_extra">%R(input=[myvar])<br></div><div class="gmail_extra">code<br><br></div><div class="gmail_extra">But we also use the name to assign the converted variable to in R, so you'd need to provide that separately:<br>

<br></div><div class="gmail_extra">%R(input={'myvar':myvar})<br></div><div class="gmail_extra">code<br><br></div><div class="gmail_extra">That is slightly more flexible, but most of the time it's going to involve unnecessary repetition, in addition to the extra punctuation.<br>

<br></div><div class="gmail_extra">Thomas<br></div></div>