Hello all,
Related question here: Dynamic options set up to extract data from a list collection
I would like to dynamically generate a “select” list from uploaded data (an XML file). I understand that one needs to define an tag using either “from_data_table” or “from_dataset” using the history or “from_parameter”. In my case I guess that “from_parameter” is the appropriate one (since I would like to get options from the input directly), however I seem to be unable to do it. Furthermore, the other options would not work since these rely on static file right?
As well, “from_parameter” is specified to be discouraged in the doc.
Does anyone have any idea how one would do that? Here is the code I have so far. Thanks a lot.
<tool id="testPreParse" name="testPreParse" version="1.0">
<description>Test the reading of an SBML file to parse the compartment names</description>
<command detect_errors="exit_code"><![CDATA[
python '$__tool_directory__/testPreParse.py' -input '$input' -output '$output'
]]></command>
<inputs>
<param name="input" format="csv" type="data" label="" />
<param name="listFirstColumn" type="select" multiple="false" label="" >
<options from_parameter="input">
<column name="name" index="1" />
</options>
</param>
</inputs>
<outputs>
<data name="output" format="txt" />
</outputs>
<help>
This is the help section. Should really write something usefull here :)
</help>
</tool>
Edit: found another link with a related question: https://biostar.usegalaxy.org/p/16059/
Edit2: I tries also using “from_data_table” option (https://galaxyproject.org/admin/tools/data-tables/). However, I am unsure how one would make this dynamic. The *.loc files are located centrally in another location and thus, does not seem to fit my needs (of dynamically generating a scroll down menu from an input file)