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

TASK-6838 - Simplify HRDetect Interface for non-advanced users #979

Merged
merged 16 commits into from
Sep 25, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
16 commits
Select commit Hold shift + click to select a range
ac623a8
wc: Force to round all scores values to the 2nd decimal point in hrde…
jmjuanes Sep 20, 2024
8956403
wc: Remove commented code in hrdetect-view #TASK-6927 #TASK-6838
jmjuanes Sep 20, 2024
b3b830d
wc: Remove intercept row in scores table of hrdetect-view #TASK-6927 …
jmjuanes Sep 20, 2024
c36b90f
wc: Promote Probability to a separate field in hrdetect-view #TASK-69…
jmjuanes Sep 20, 2024
c6b053b
wc: Remove Probability row from scores table #TASK-6927 #TASK-6838
jmjuanes Sep 20, 2024
1ef296d
wc: Minor code style fix in hrdetect-view #TASK-6927 #TASK-6838
jmjuanes Sep 20, 2024
7b2c8ec
wc: Fix extra curly brace in filter method of scores table config #TA…
jmjuanes Sep 20, 2024
ff3a9e5
wc: Add transform method to sort scores table in hrdetect-view #TASK-…
jmjuanes Sep 20, 2024
a199b9b
wc: Rename Scores section title to Contributions #TASK-6927 #TASK-6838
jmjuanes Sep 20, 2024
920c580
wc: Remove the field Fit Signatures File from mutational signatures a…
jmjuanes Sep 20, 2024
5fb76fa
wc: Remove the field Fit Rare Signatures File from mutational signatu…
jmjuanes Sep 20, 2024
45f962f
wc: Remove some fields in hrdetect analysis form #TASK-6927 #TASK-6838
jmjuanes Sep 20, 2024
24cba8a
wc: Rename advanced parameters section in hrdetect analysis form #TAS…
jmjuanes Sep 20, 2024
5dae217
Merge branch 'release-3.x.x' into TASK-6838
jmjuanes Sep 20, 2024
6fc4d97
Merge branch 'release-3.x.x' into TASK-6838
jmjuanes Sep 25, 2024
83f0c76
Merge branch 'release-3.x.x' into TASK-6838
jmjuanes Sep 25, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
46 changes: 1 addition & 45 deletions src/webcomponents/clinical/analysis/hrdetect-analysis.js
Original file line number Diff line number Diff line change
Expand Up @@ -115,10 +115,6 @@ export default class HRDetectAnalysis extends LitElement {
sampleId: this.toolParams.query?.sample,
snvFittingId: this.toolParams.snvFittingId,
svFittingId: this.toolParams.svFittingId,
snv3CustomName: this.toolParams.snv3CustomName || "",
snv8CustomName: this.toolParams.snv8CustomName || "",
sv3CustomName: this.toolParams.sv3CustomName || "",
sv8CustomName: this.toolParams.sv8CustomName || "",
bootstrap: !!this.toolParams.bootstrap,
};

Expand Down Expand Up @@ -290,48 +286,8 @@ export default class HRDetectAnalysis extends LitElement {
],
},
{
title: "Advanced Parameters",
title: "HRDetect Parameters",
elements: [
{
title: "SNV3 Custom Name",
field: "snv3CustomName",
type: "input-text",
display: {
help: {
text: "Custom signature name that will be considered as SNV3 input for HRDetect.",
},
},
},
{
title: "SNV8 Custom Name",
field: "snv8CustomName",
type: "input-text",
display: {
help: {
text: "Custom signature name that will be considered as SNV8 input for HRDetect.",
},
},
},
{
title: "SV3 Custom Name",
field: "sv3CustomName",
type: "input-text",
display: {
help: {
text: "Custom signature name that will be considered as SV3 input for HRDetect.",
},
},
},
{
title: "SV8 Custom Name",
field: "sv8CustomName",
type: "input-text",
display: {
help: {
text: "Custom signature name that will be considered as SV8 input for HRDetect.",
},
},
},
{
title: "Bootstrap",
field: "bootstrap",
Expand Down
21 changes: 18 additions & 3 deletions src/webcomponents/clinical/analysis/hrdetect-view.js
Original file line number Diff line number Diff line change
Expand Up @@ -169,20 +169,35 @@ class HRDetectView extends LitElement {
},
},
{
name: "Scores",
name: "Probability",
field: "scores",
display: {
format: scores => {
return scores.find(row => row.key?.toLowerCase?.() === "probability")?.value?.toFixed?.(2) || "-";
},
},
},
{
name: "Contributions",
field: "scores",
type: "table",
display: {
// style: "width:auto",
showHeader: false,
filter: data => (data || []).filter(row => {
return !["intercept", "probability"].includes(row?.key?.toLowerCase?.());
}),
transform: data => data.toSorted((a, b) => b.value - a.value),
columns: [
{
title: "key",
field: "key"
},
{
title: "value",
field: "value"
field: "value",
display: {
format: value => value.toFixed(2),
},
},
],
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -163,8 +163,6 @@ export default class MutationalSignatureAnalysis extends LitElement {
fitNBoot: this.toolParams.fitNBoot,
fitThresholdPerc: this.toolParams.fitThresholdPerc,
fitThresholdPval: this.toolParams.fitThresholdPval,
fitSignaturesFile: this.toolParams.fitSignaturesFile,
fitRareSignaturesFile: this.toolParams.fitRareSignaturesFile,
};

// Check if we have provided an existing signature list
Expand Down Expand Up @@ -411,42 +409,6 @@ export default class MutationalSignatureAnalysis extends LitElement {
field: "fitNBoot",
type: "input-text",
},
{
title: "Fit Signatures File",
field: "fitSignaturesFile",
type: "custom",
display: {
render: (fitSignaturesFile, dataFormFilterChange) => html`
<catalog-search-autocomplete
.value="${fitSignaturesFile}"
.resource="${"FILE"}"
.opencgaSession="${this.opencgaSession}"
.config="${{multiple: false}}"
.searchField="${"id"}"
.query="${fileQuery}"
@filterChange="${e => dataFormFilterChange(e.detail.value)}">
</catalog-search-autocomplete>
`,
},
},
{
title: "Fit Rare Signatures File",
field: "fitRareSignaturesFile",
type: "custom",
display: {
render: (fitRareSignaturesFile, dataFormFilterChange) => html`
<catalog-search-autocomplete
.value="${fitRareSignaturesFile}"
.resource="${"FILE"}"
.opencgaSession="${this.opencgaSession}"
.config="${{multiple: false}}"
.searchField="${"id"}"
.query="${fileQuery}"
@filterChange="${e => dataFormFilterChange(e.detail.value)}">
</catalog-search-autocomplete>
`,
},
},
]
}
];
Expand Down
Loading