molgenis / molgenis-emx2

MOLGENIS EMX2, the latest version of the MOLGENIS data platform.
GNU Lesser General Public License v3.0
11 stars 16 forks source link

As soon as cohort filters are applied, the variable explorer should not show cohorts which are selected but which have no mappings for the variables selected #3866

Closed EleanorHyde-UMCG closed 2 weeks ago

EleanorHyde-UMCG commented 3 weeks ago

What version of EMX2 are you using (see footer) v10.79.3-SNAPSHOT

Describe the bug Too many cohorts are shown in the variable explorer: those selected but crucially WITHOUT a mapping to the variable(s) selected should not be shown in the harmonisation matrix.

To Reproduce Steps to reproduce the behavior:

  1. Go to https://preview-emx2-pr-3865.dev.molgenis.org/catalogue-demo/ssr-catalogue/testNetwork1/variables [or the equiv in the correct prev / or in acc]
  2. Click on Harmonisations.
  3. See that there are 8 variables, with different mappings. testCohort2 has no mappings at all, but is shown. This is correct, because the cohort filter has not been applied.
  4. Select testcohort2 only in the list of cohorts bottom left.
  5. See that zero variables are displayed. This is correct.
  6. Select testcohort3 alongside testcohort2.
  7. See that all the variables for which testcohort3 has a mapping are shown (4), but that testcohort2 is ALSO shown. Display of testcohort 2 is incorrect.

Expected behavior In step 7, testcohort2 should not be shown, because it has no mappings to the variables filtered on. As soon as the cohort filter is applied, only cohorts with mappings to the variables which result from the filtering are shown.

Screenshots No cohortfilters applied: correct image

Only testcohort2 filtered: correct image

testcohort2 and testcohort3 selected: incorrect, testcohort2 should not be shown at all image

CONVERSELY:

  1. Go to the list of variables for testnetwork1: https://data-catalogue-acc.molgeniscloud.org/testCatalogue/ssr-catalogue/testNetwork1/variables
  2. Click on testVarRepeats.
  3. In the 'harmonisation status' block, all the repeats are shown with their mappings to the cohorts. Testcohort2 should be shown here because this matrix shows all the cohorts of the network in question with their mappings (fully, partially, NA). Leaving testcohort2 out here is incorrect.

Screenshots image

Desktop (please complete the following information):

EleanorHyde-UMCG commented 3 weeks ago

(see the 'conversely' part underneath as well, added later)

mswertz commented 3 weeks ago

Is this not a feature? I would like to explicitly see that testcohort2 has no mappings?

mswertz commented 3 weeks ago

the 'conversely' is also interesting but a seperate issue. And there,

option1: we would like to show all cohorts that have mapping unless specific cohorts are selected then I would also like to see those cohorts.

OR

option2: do you want to have all cohorts that are partner in the network. And if so, what to do outside a network.

I would prefer option 1

EleanorHyde-UMCG commented 3 weeks ago

bug #3868 has been created for the 'conversely' part

mswertz commented 2 weeks ago

Works as intended. I don't want to do this

EleanorHyde-UMCG commented 2 weeks ago

Within the team we are in agreement that displaying cohorts actively selected whether or not they have mappings to the variables selected is beneficial to the user. This is not a bug and will be closed!