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

[Platform] Add GWAS credible sets widget to variant page #390

Merged
merged 8 commits into from
Jun 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
5 changes: 5 additions & 0 deletions apps/platform/src/pages/VariantPage/Profile.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,19 +9,22 @@ import {
import InSilicoPredictorsSummary from "sections/src/variant/InSilicoPredictors/Summary";
import EVASummary from "sections/src/variant/EVA/Summary";
import UniProtVariantsSummary from "sections/src/variant/UniProtVariants/Summary";
import GWASCredibleSetsSummary from "sections/src/variant/GWASCredibleSets/Summary";
import PharmacogenomicsSummary from "sections/src/variant/Pharmacogenomics/Summary";

import ProfileHeader from "./ProfileHeader";

const InSilicoPredictorsSection = lazy(() => import("sections/src/variant/InSilicoPredictors/Body"));
const EVASection = lazy(() => import("sections/src/variant/EVA/Body"));
const UniProtVariantsSection = lazy(() => import("sections/src/variant/UniProtVariants/Body"));
const GWASCredibleSetsSection = lazy(() => import("sections/src/variant/GWASCredibleSets/Body"));
const PharmacogenomicsSection = lazy(() => import("sections/src/variant/Pharmacogenomics/Body"));

const summaries = [
InSilicoPredictorsSummary,
EVASummary,
UniProtVariantsSummary,
GWASCredibleSetsSummary,
PharmacogenomicsSummary,
];

Expand Down Expand Up @@ -51,6 +54,7 @@ function Profile({ varId }: ProfileProps) {
<InSilicoPredictorsSummary />
<EVASummary />
<UniProtVariantsSummary />
<GWASCredibleSetsSummary />
<PharmacogenomicsSummary />
</SummaryContainer>

Expand All @@ -65,6 +69,7 @@ function Profile({ varId }: ProfileProps) {
<UniProtVariantsSection id={varId} label='NO-LABEL!' entity={VARIANT} />
</Suspense>
<Suspense fallback={<SectionLoader />}>
<GWASCredibleSetsSection id={varId} label='NO-LABEL!' entity={VARIANT} />
<PharmacogenomicsSection id={varId} label='NO-LABEL!' entity={VARIANT} />
</Suspense>
{/* NEED ANYTHING IN <PrivateWrapper> ???? see evidence page */}
Expand Down
43 changes: 43 additions & 0 deletions apps/platform/src/pages/VariantPage/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,49 @@ export type UniProtVariantsType = {
"target.approvedSymbol": string,
"disease.id": string,
"disease.name": string,
};

// ==================
// GWAS Credible Sets
// ==================

export type GWASCredibleSets = {
variantId: string,
study: {
id: string,
traitFromSource: string,
disease: {
id: string,
name: string,
}
},
pValueMantissa: number,
pValueExponent: number,
beta: number,
ldPopulationStructure: [
{
ldPopulation: string,
relativeSampleSize: number,
}
],
finemappingMethod: string,
l2g: {
score: string,
target: {
id: string,
approvedSymbol: string,
}
},
locus: [
{
variantId: string,
r2Overall: number,
posteriorProbability: number,
standardError: number,
is95CredibleSet: boolean,
is99CredibleSet: boolean,
}
]
};

// ================
Expand Down
Loading
Loading