-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Discussion thread on key use cases, interface rearrangement #4
Comments
Actually, I think it's a good idea, it streamlines a lot and indeed fits with a 'cli' like tool, so probably would be clearer to a user. One additional note (although this can come later), is often I only need to build a report for archaeologists of a single (precious, in all cases ;)) sample. So, if I understand correctly, for the |
Yes, that's possible. I also think we should make it possible to select a specific site, or in fact multiple sites. And with respect to tags, I think we should allow a system where we list - say everything for which a specific tag is set at a specific level. So perhaps something like I think we need to come up with a general selection grammar or something... well, one step at a time. |
Let's revive the sidora hackhour on Friday. "Typical" workflows as the one outlined above will help to narrow down, what this interface should do. The idea to transform this repo again to an R package is good, but I believe it will be difficult to write functions that are both useful for command line data exploration and R data analysis. Within R you want tidy data structures, on the command line you want easily digestible and well readable output (and I want cool ascii plots). IMHO we should do one thing good and not try to support two different interfaces at once. R users should rely on the core package only. Probably our work on the cli-backend-package will reveal new functions that should be part of core. Beyond the differences in output and purpose it's also confusing to require the user to effectively use two packages for exploring Pandora. One vaguely general and the other vaguely more specific. |
I unfortunately am finding it more and more difficult to find time to join the hackathon at the moment due to continued childcare and piling up deadlines :. But I see what you mean. Why couldn't even the 'specific' reporting functions also just not go in sidora.core? I suspect only people who want to get into the nitty gritty would go into sidora.core anyway. |
OK, you've convinced me about the separation of keeping the R API in sidora.core, and focus the cli only on bash usage. Sounds all good. |
Clemen's and I decided to try and solidify more of the design decisions, so will make a draft here. General Overviewsidora.cli will have a verb - noun 'like' grammar. e.g. etc. 'Verb' Module DescriptionsListSimply gives a list of each entity of a given criteria in a row-wise fashion. E.g. I want all sites for a project: AAA ViewProvides all information for a single 'row' of a pandora table. This is essentially all the information that is displayed when on the Pandora Web UI. SummariseGives summaries (totals, means, maps, lists etc.) of a given noun. For example: The samples are from these countries, with LAT:LON on a fancy ascii nerd-map. TabulateThis provides all information of a multiple entries of a pandora table in a TSV format. Default displayed is a markdown table. A export function would allow exporting as a TSV file.
Reporttbc. |
So what "noun" means depends on the Verb:
|
Correct. Summarise - good question @nevrome ? |
Since my work with ruby I have a deep-rooted dislike for every approach that forces context-sensitive plurals. I vote for only singulars everywhere. |
That's OK, I more meant conceptually... not clear to me whether |
Each of these modules (except list) takes an entity type and an entity id. What you suggest for list is now part of tabulate. I think we should quickly talk about it in our debriefing session later. |
ToDos:
Focus: Data driven analysis approach |
General Roadmap discussion:
WebApp will be the focus for non-bioinformaticians, e.g. to provide smmary statisics for PIs; lab tracking (e.g. progress tables) for lab techs. James will finish simple tasks ( Clemens will work on summary, which will also feed into later work for James and Stephan when we start developing the |
I fell in love with this extremely neat, documentation string based CLI interface definition with docopt. How would you like an interface like this, @stschiff and @jfy133?
|
That looks really nice! Much more what I would be familiar with! |
Looks beautiful, indeed! |
We currently have this very nice and flexible module-based approach, where I can say
./sidora.R -m progress_table
and it creates a progress table. However, it's a bit funny that - for example - the project filter is a global option. I think that design will create problems later.For example, here is an exploratory workflow that I can imagine might be useful:
here, 1-3 would not allow for a project selection (because you are printing all), while 4-6 involve selecting a project.
I would therefore suggest we aim for a more controlled, less free, approach to the interface, where we have subcommands of the sort
./sidora.R list --projects
-> listing all projects./sidora.R list --projects --withStats
-> as above, but with some key numbers summarised (nr of sites, individuals, ...)./sidora.R list --tags
-> listing all tags, with optional--withStats
./sidora.R list --sites
-> listing all sites, with optional--withStats
./sidora.R view --project=XX
-> list progress table./sidora.R view --tag=XX
-> similar./sidora.R view --project=XX --columns=X,Y,Z
-> show only the selected columns./sidora.R view --project=XX --columns=X,Y,Z --output=html
-> create reportSo here I can see we already need
list
andview
subcommands, but I'm sure we'll have a lot more in the future. But this would go away from the very flexible module-based approach, but make a more restrictive set of sub-commands.In terms of internal design, I think we should design this repo as a proper R package. So all functionality shown above from the command line should be also available as simple R functions (called for example
sidora_list(...)
andsidora_view(...)
). Then, the CLI script would simply call those functions. Thereby we have covered both the interactive, programmatic use-case within R, and also the more immediate bash-based approach.Destroy.
The text was updated successfully, but these errors were encountered: