Open keflavich opened 6 years ago
This is likely a repeat of https://github.com/glue-viz/glue/issues/702
So, this is very similar to #702, but much simpler. This case should just work, afaict. In this case, there is nothing special about sequential selections of _idx
(or at least, there absolutely should not be)
Commenting to second and follow this issue, which I am also having.
Just to check, did you set up the links yourself, or did glue do it automatically?
We set up the links ourselves. Linking "structure" in the dendrogram file and the "_idx" column in our ipac table. And it does seem to work perfectly, but only when selecting on _idx explicitly and sequentially.
The default kind of linking in glue is such that only selections done along linked components work, hence the behavior you are seeing. There is another kind of link in glue not yet exposed through the GUI (but will be soon) which is a 'key join' which can be set up using the following method:
http://docs.glueviz.org/en/stable/api/glue.core.data.Data.html#glue.core.data.Data.join_on_key
See the docstring above for how this works.
However, note that normally if you are reading in a file produced by astrodendro, glue sets up links itself automatically using join_on_key so in principle you shouldn't have to do this and it should just work out of the box:
https://github.com/glue-viz/glue/blob/master/glue/plugins/dendro_viewer/data_factory.py#L109
If it doesn't, it's a bug :) Note that setting up links manually with the link editor will break this behavior and replace it with a sub-optimal link, which is what you are seeing.
I don't think that second point is true for catalogs produced by astrodendro, is it?
(we're only interested in the catalog, not the dendrogram - the dendrogram is just the link from the catalog to the data)
@keflavich - ah yes good point, it doesn't work for the catalogs. Can you see if you can use join_on_key
from the IPython terminal inside glue to get the behavior you want? I'll add a way to do this via the GUI soon.
When I have a dendrogram catalog linked via the structure ID to the dendrogram file (including image), the structures selected in the plot only highlight in the image if one of the plot axes is the linked structure ID and you select on the structure ID; I believe this occurs because the structure ID selection is required to be sequential. This is not useful.
Examples: Good:
bad: