You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@taverna.apache.org by N....@lumc.nl on 2015/09/21 10:17:50 UTC

Passing list of lists (or any higher dimension) to R in Taverna?

Dear all,

Perhaps this has been addressed elsewhere, but I could not find anything. What is the best, or recommended, way of passing a list of lists (or a list of lists of lists, etc.) to an Rshell in Taverna? The lists in the list are not of equal length, i.e. not a perfect 2D matrix, and some lists are empty. If possible, I would like to capture it as a list structure in R and go from there.

The solution I came up with was to flatten the list, inserting markers for each sublist, then pass this single list to and parse it in R. This works, but is hardly elegant (some may say it is even extremely inelegant).


All the best,

Magnus Palmblad

Re: Passing list of lists (or any higher dimension) to R in Taverna?

Posted by alaninmcr <al...@googlemail.com>.
On 21/09/2015 09:17, N.M.Palmblad@lumc.nl wrote:
> Dear all,

Hello Magnus

> Perhaps this has been addressed elsewhere, but I could not find
> anything. What is the best, or recommended, way of passing a list of
> lists (or a list of lists of lists, etc.) to an Rshell in Taverna? The
> lists in the list are not of equal length, i.e. not a perfect 2D matrix,
> and some lists are empty. If possible, I would like to capture it as a
> list structure in R and go from there.
>
> The solution I came up with was to flatten the list, inserting markers
> for each sublist, then pass this single list to and parse it in R. This
> works, but is hardly elegant (some may say it is even extremely inelegant).

It may be possible to transfer it as an RExpression. I haven't seen any 
elegant way of handling lists of lists.

> All the best,
>
> Magnus Palmblad

Alan