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

Samplegeno & Assorted Fixes (samplegeno-ui-2) #225

Merged
merged 18 commits into from
Oct 8, 2020
Merged

Conversation

Bianca-Morris
Copy link
Member

@Bianca-Morris Bianca-Morris commented Oct 5, 2020

Started as just samplegeno fixes, but it was so small that I lumped in the other updates, too.

Changes:

Samplegeno Table

  • Shorten ref genotype in header.
  • Move ref shortening code out into own function (maybe should memoize/move to util?).

Filtering Table

  • Make all columns narrower so more is shown at first.
  • Incorporate scientific notation to 3 digits for gnomad column. (E.g. 1.20, 0.120. 0.0120, 1.2e-3, 1.2e-4 etc).
  • If genes has more than one item (show all, but comma separate the different entries).
    • Note: Wasn't able to really test this as well as would like on local... need to deploy to get a better idea if it works. Ran into failed validation/infinite validation bug & XML error when attempting to add another gene item to a variant for testing on local. This may inform why some of those SV infinite validation issues were happening previously... incomplete error handling?)
    • Note 2: This column might also be a good candidate for memoization due to looping, string joining?
  • Fix 3-row column word-wrapping and text overlap issues.
  • Enabled sort for each field visible in each column; most seem to work except for coding effect, which... doesn't behave entirely as expected. Disabled sorting for variant, bamsnap.
  • Add comma between "Gene" and "Transcript"
  • Change capitalization of "GnomAD" to "gnomAD"

Case Search Table

  • Update variant ingestion status to come from case.vcf_file.

Case Bioinformatics Tab

  • Add comma decoration to large numeric values in stats section.
  • Switch pedigree button to be a provenance button that links to current case.vcf_file's provenance graph

To-Do:

  • Bump version before merge

Copy link
Contributor

@alexkb0009 alexkb0009 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code looks good! (Haven't tested on local / assuming working as expected)


const {
original_pedigree: { display_title: pedFileName } = {},
// original_pedigree: { display_title: pedFileName } = {},
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just commented this out for the time being... not sure if the pedFileName is necessary anymore? I assume if no one gets upset about this not being visible anymore, it's not necessary.

@@ -612,7 +613,7 @@ const BioinfoStats = React.memo(function BioinfoStats(props) {
: null }
</div>
<div className="col-sm-4">{/* 4,769,578 */}
{ (msaStats.totalVariants && msaStats.totalVariants.value) || "" }
{ (msaStats.totalVariants && msaStats.totalVariants.value) ? decorateNumberWithCommas(msaStats.totalVariants.value): "" }
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

May need to do some more work here to make sure these values are always Numbers, not strings. For now, decorateNumberWithCommas falls back to returning the string value anyway, so worst case scenario, it just doesn't add commas/renders the number as it currently is.

@Bianca-Morris Bianca-Morris merged commit 364636b into master Oct 8, 2020
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

Successfully merging this pull request may close these issues.

2 participants