Skip to content
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

Allow filters on participant characteristics #4

Closed
brittsikora opened this issue Apr 14, 2016 · 4 comments
Closed

Allow filters on participant characteristics #4

brittsikora opened this issue Apr 14, 2016 · 4 comments
Milestone

Comments

@brittsikora
Copy link

Filter by subgroup, (sex, median age split, and active vs. placebo when unblinded)

@jwildfire
Copy link
Contributor

Adding participant-level filters on the primary page is possible (see http://graphics.rhoworld.com/tools/aeexplorer/example4/), but complicated. The most robust way to handle it is to have two separate data inputs for the chart. One event-level data set for AEs and one participant-level data set for demographics. Would break backwards compatibility, but will consider for version 3.

Other options are possible, but are going to involve complex settings for filters, which I want to avoid.

@jwildfire jwildfire added this to the 3.0.0 milestone Jan 7, 2017
@jwildfire jwildfire changed the title Filter AE Table by Subgroup Allow filters on participant characteristics Jan 8, 2017
@jwildfire
Copy link
Contributor

jwildfire commented Jan 8, 2017

I'm leaning towards adding a type parameter to filter specifications instead of requiring multiple files. Options for settings.filters[x].type would be:

  • 'event' for filters related to the AEs themselves, like event Severity (this is the currently supported functionality)
  • 'participant' for filters related to the participants, like participant Gender (not currently supported)

The new filters specification would look like this:

filters:  [   
  {'value_col': 'AESER'
  ,'label': 'Serious?'
  ,'type':'event'} //new in v3.0.0
  ,{'value_col': 'GENDER'
  ,'label': 'Gender'
  ,'type':'participant'}] //new in v3.0.0

I think code changes would be isolated to the following files:

  • /src/chart/AETable/util/prepareData.js - Changes to the algorithm creating chart.filtered_data (this would represent the bulk of the updates)
  • /src/chart/AETable/controls/custom/init.js - Add a label to each filter showing the type
  • /src/chart/defaultSettings.js - update filter defaults to include type

I'll start on a branch off of refactor with this approach and see how it goes.

@jwildfire
Copy link
Contributor

jwildfire commented Jan 8, 2017

Seems like approach above will work well. Initial commit branch v3-filters. Needs some more clean-up and testing, but here's a working example.

@jwildfire
Copy link
Contributor

merged in to refactor will be released in v3

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants