Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Add interactive shiny interface to procspec() #187

Open
Bisaloo opened this issue Jan 18, 2020 · 4 comments
Open

Add interactive shiny interface to procspec() #187

Bisaloo opened this issue Jan 18, 2020 · 4 comments
Assignees

Comments

@Bisaloo
Copy link
Collaborator

Bisaloo commented Jan 18, 2020

I would be great if users could interactively select the bounds for procspec(). It would be especially useful for species that have multiple peaks in various places (hummingbirds, or Devi's beetles).

Should this be in pavo or in an extension package that adds a shiny interface to various pavo functions (or that could join the colrverse)?

I will probably need this soon so assigning to myself.

@Bisaloo Bisaloo self-assigned this Jan 18, 2020
@thomased
Copy link
Collaborator

Hmm. It'd be cool — couple of random thoughts. In principle most of pavo could be shiny'd for R-phobic users, from loading & processing specs to modelling & plotting etc. Raf has that neat tcsplot/model example in a repo somewhere. If you saw it going that direction over whatever timeframe I'd think that'd be worth a package-sized extension (from only limited experience with shiny though).

For the smaller-scale case of an interactive procspec(), I wonder how far you could get with some locator() trickery without the baggage of shiny? I'd have to have a play, not sure if it's up to the task — just a thought.

@Bisaloo
Copy link
Collaborator Author

Bisaloo commented Jan 19, 2020

Some quick answers that we can discuss:

Yes, most of pavo can be shiny'd. I also started a shiny interface around the same time as Raf. The file import and pre-processing were working quite well but I didn't go all the way to vision models and colour spaces IIRC. If we had unlimited time, it would be a cool project (especially since we have two proofs of concepts on different parts that we might be able to merge).

But beyond that, I think there are certain part where a graphical interface would be more useful than just catering to R-phobic users. For example, in the case I'm presenting in this issue, I can't think of a script clever enough to go through all spectra one by one and identify the various peaks. It's possible but definitely not an easy task. So a graphical interface here would be great for everybody, even advanced users.

Regarding locator() vs shiny, yes, it should be possible but not as convenient IMO because it's still less interactive. In shiny, you can have sliders and drag elements with your cursor, which is not possible with locator()

@thomased
Copy link
Collaborator

Cool, that all makes sense — sounds worthwhile.

As to whether it's incorporated or sits in its own package, I'm not sure I have a good enough sense of how heavy it all is & what it'd look like to have a strong opinion atm. I'm on board with the lightr-style use of tightly integrated packages if you're leaning that way, and it could make extensibility simpler if we're later inclined to shinify other bits of pavo (or the whole package, given infinite time). But if it's just a matter of a new argument being dropped in procspec() then it may be simplest at this stage to just roll it in. I'm open

@Bisaloo
Copy link
Collaborator Author

Bisaloo commented May 14, 2020

# for free to join this conversation on GitHub. Already have an account? # to comment
Projects
None yet
Development

No branches or pull requests

2 participants