i currently writting a wrapper for the tool MaAsLin3 and i have some trouble therer.
I need to provide a parameter, named formula, in the followed way: ~ header_name1 + header_name2 …. . This need to be string the only way to make this work is to make this as an text input so the user need to write it manually. Is there a way to use the data_column type as for this? I tried a lot to work with it but i didnt found a way to make it work with it.
I need to provide a parameter, named reference, the problem here is that there are 2 symbol needed to for this as an text input. The first is easy since it is only ‘,’ but the real problem is ‘;’. Since it this will be parsed to an ‘X’ in the command line threre is no way to make it work, at least i didnt found any. Could be there a way to overwrite the parse such that is will not be an ‘X’ in the command line or now? or how could i make it work when the user has to input this, as an example now, diagnosis,CD;dysbiosis_state,dysbiosis_UC. The first is the header_name and after the reference, so this i comma seperated while when using muliple references they will be semicolon seperaded.
It would be nice if at least the second point can be answerd since the first is only a quallity problem while the second is a functionality problem.
Both of these would be recommended. That way you don’t have to start from scratch (instead, use the current wrapper as a baseline) and creating all the artifacts to support your wrapper will be easier (from using Planemo).
One example is here for your second question about the “reference” parameter modeling. The current wrapper is using commas , for the entire string, but the wrapper “knows” that these values come in pairs and parses those out of the string input for the command line (avoiding problematic characters).
Code
Then one of the tool tests
Then for your “formula” parameter modeling, I think this tool wrapper is also doing this for a few variables and you could use the same methods. A tool form can reference specific columns in one of the inputs, based on the header line, for the user to then choose on the tool form. See the parts of the tool wrapper for the options “Interactions: Fixed effects” and “Random effects”. Both of these have a pull down menu with the column cited along with the header label as a key pair that the user can select at runtime.
Please give this a review and let us know what you think! Existing tool wrappers are a great resource, whether you choose to pull in everything and update, or branch off into something new.
no im not updading the current MaAsLin2 wrapper since MaAsLin3 devs are not sure how often they update the GitHub package so i thougt it is better to have both tools up just to make sure that the users can choose which tool they want to use.
I use planemo for the development yes and i also use MaAsLin2 existing wrapper as baseline but the problem now is that MaAsLin3 is sensetiv to how to input certain paramenter.
The formula parameter in this case is one of this and the only problematic parameter in this case. My workaround was to let the user type the formula in galaxy instead of using the data_column because using this with awktogether give me something which the tool doesnt like so i thought i ask here if there might be a way to use it since it is user friendly.
For an example the output from awk would look like this: “header_name1” + “header_name2” + “… .All of this should be one string together and not only the header_names which make it not usable for MaAsLin3.
For the reference MaAsLin3 doesnt do it like MaAsLin2 they use to seperate the reference pairs with ‘;’ insetead of doing all with ‘,’. My thought would be to use a symbol which getting parsed correctly and replace it in the command line but in my eyes this would be, depending on the symbol, not userfriendly and befor i doing this i thought i ask here if there is way to use ‘;’,
Thank you for the help i hope i ´could clarifiy enought to understanding the problem!
I think you’ll need to ask the IUC what to do here. You need the “raw” values to avoid the extra quoting around terms, but I’m not sure about the preferred “safe” way to do that.
Then, ; characters are getting sanitized.
What about avoiding the user inputting that at all, and instead adding in a repeating parameter block that expands on the form?
Or is prompted to input pairs like this? I sort of like this better since it removes all formatting from what the user is expected to provide. They just type in terms into prompted and labeled fields?
diagnosis
nonIBD
dysbiosis_state
none
antibiotics
No
*expanding repeat block*
then the wrapper constructs the full string with the , and ; characters?
Yes and is has to be like this otherwise the tool doesnt work.
Since you dont know any other way to resolve this i will keep the workaround that the user has to write the complet formula on his own with the + and without the ~ since this will also be parsed as an X.
I thought so as well to use repeat and built it the string via command line. Since you dont know any other way around it will use this!
Thank you for the asnwers if there is any other problems i make another replay here!
Glad you have some working ideas now! And definitely come back if anything else comes up or these don’t work out in a way you like.
Update: I decided to ask the IUC about the first item. Maybe they have more ideas. Let’s keep the discussion here with all the context. Cross-link just as a reference.