Thanks for the reply. I tried to emulate that example but got stuck
when I wanted to choose the column based on a metadata value. It
looks like the column number in the extract_GFF_Features tool is
selected as an input parameter. In our case, the number of the column
that contains the values for the select parameter already exists as a
metadata value. I'd ideally like to use this value rather than have
the user specify the column.
On Tue, Jan 5, 2010 at 3:21 PM, Greg Von Kuster <greg(a)bx.psu.edu> wrote:
Galaxy already provides the ability to do this using the UniqueValueFilter
class in ~/lib/galaxy/tools/parameters/dynamic_options.py.
For an example of how this works, see the tool config for the
extract_GFF_Features tool in ~/tools/extract, which includes tags like the
<param name="feature" type="select"
features" help="Multi-select list - hold the appropriate key while clicking
to select multiple columns">
<column name="name" index="0"/>
<column name="value" index="0"/>
<filter type="unique_value" name="unique"
On Dec 20, 2009, at 11:06 PM, Martin Aryee wrote:
Thanks for the feedback. I've now been able to use set_meta() to set my
metadata as I'd like.
Regarding the SelectToolParameter, I'd like to dynamically generate the
options from all the unique values in a column in an input data set. The
column number is specified in the dataset's metadata. From the tool config
section on the wiki page it doesn't look like this particular functionality
is available. Am I right in thinking I should go ahead and define a new
On Fri, Dec 18, 2009 at 11:04 AM, Greg Von Kuster <greg(a)bx.psu.edu> wrote:
> Hello Martin,
> From your brief description of what you are trying to do, I don't see the
> need for tool hooks. The SelectToolParameter can be dynamically generated
> using tool config settings. Metadata is set as part of the job, so the
> set_meta() method of the data type of the output dataset can be enhanced to
> set whatever metadata you want.
> We have been migrating what used to be done in tool code hooks into the
> Galaxy framework, although the framework still supports hooks for now.
> On Dec 9, 2009, at 2:17 PM, Martin Aryee wrote:
> I'm trying to work out how to run custom python code as a tool is loaded
> (to get generate options for a select parameter) and after job completion
> (to set metadata). It looks like the <code> tags would have been the place
> to point to my code, but since they are now deprecated I was wondering if
> someone could point me in the right direction?
> Martin Aryee.
> galaxy-dev mailing list
> Greg Von Kuster
> Galaxy Development Team
Greg Von Kuster
Galaxy Development Team
Yegnasubramanian Lab / Irizarry Lab
Johns Hopkins Schools of Medicine and Public Health