@sjcrh/proteinpaint-types 2.84.0 → 2.85.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/routes.ts +28847 -0
- package/package.json +17 -13
- package/src/Mclass.js +0 -0
- package/src/checkers/routes.js +167 -0
- package/src/dataset.js +0 -0
- package/src/fileOrUrl.js +0 -0
- package/src/filter.js +0 -0
- package/src/genome.js +0 -0
- package/src/index.js +66 -0
- package/src/routes/brainImaging.js +11 -0
- package/src/routes/brainImagingSamples.js +11 -0
- package/src/routes/burden.js +44 -0
- package/src/routes/dataset.js +12 -0
- package/src/routes/dsdata.js +12 -0
- package/src/routes/dzimages.js +12 -0
- package/src/routes/errorResponse.js +0 -0
- package/src/routes/filter.gdc.js +0 -0
- package/src/routes/gdc.maf.js +17 -0
- package/src/routes/gdc.mafBuild.js +12 -0
- package/src/routes/gdc.topMutatedGenes.js +12 -0
- package/src/routes/genelookup.js +12 -0
- package/src/routes/genesetEnrichment.js +12 -0
- package/src/routes/genesetOverrepresentation.js +12 -0
- package/src/routes/healthcheck.js +23 -0
- package/src/routes/hicdata.js +12 -0
- package/src/routes/hicgenome.js +29 -0
- package/src/routes/hicstat.js +12 -0
- package/src/routes/isoformlst.js +12 -0
- package/src/routes/ntseq.js +12 -0
- package/src/routes/pdomain.js +12 -0
- package/src/routes/routeApi.js +0 -0
- package/src/routes/samplewsimages.js +12 -0
- package/src/routes/snp.js +11 -0
- package/src/routes/termdb.DE.js +13 -0
- package/src/routes/termdb.boxplot.js +12 -0
- package/src/routes/termdb.categories.js +48 -0
- package/src/routes/termdb.cluster.js +12 -0
- package/src/routes/termdb.cohort.summary.js +12 -0
- package/src/routes/termdb.cohorts.js +12 -0
- package/src/routes/termdb.descrstats.js +48 -0
- package/src/routes/termdb.numericcategories.js +12 -0
- package/src/routes/termdb.percentile.js +49 -0
- package/src/routes/termdb.rootterm.js +27 -0
- package/src/routes/termdb.sampleImages.js +12 -0
- package/src/routes/termdb.singleSampleMutation.js +12 -0
- package/src/routes/termdb.singlecellDEgenes.js +12 -0
- package/src/routes/termdb.singlecellData.js +12 -0
- package/src/routes/termdb.singlecellSamples.js +12 -0
- package/src/routes/termdb.termchildren.js +28 -0
- package/src/routes/termdb.termsbyids.js +12 -0
- package/src/routes/termdb.topTermsByType.js +12 -0
- package/src/routes/termdb.topVariablyExpressedGenes.js +12 -0
- package/src/routes/termdb.violin.js +49 -0
- package/src/routes/tileserver.js +12 -0
- package/src/routes/wsimages.js +12 -0
- package/src/terms/categorical.js +0 -0
- package/src/terms/condition.js +0 -0
- package/src/terms/geneExpression.js +0 -0
- package/src/terms/geneVariant.js +0 -0
- package/src/terms/metaboliteIntensity.js +0 -0
- package/src/terms/numeric.js +0 -0
- package/src/terms/q.js +0 -0
- package/src/terms/samplelst.js +0 -0
- package/src/terms/singleCellCellType.js +0 -0
- package/src/terms/singleCellGeneExpression.js +0 -0
- package/src/terms/snp.js +0 -0
- package/src/terms/snps.js +0 -0
- package/src/terms/term.js +0 -0
- package/src/terms/tw.js +0 -0
- package/src/terms/updated-types.js +0 -0
- package/src/termsetting.js +0 -0
- package/src/test/numeric.type.spec.js +117 -0
- package/src/vocab.js +0 -0
- package/src/Mclass.ts +0 -8
- package/src/dataset.ts +0 -1575
- package/src/docs.json +0 -16417
- package/src/fileOrUrl.ts +0 -15
- package/src/filter.ts +0 -125
- package/src/genome.ts +0 -123
- package/src/index.ts +0 -57
- package/src/routes/brainImaging.ts +0 -42
- package/src/routes/burden.ts +0 -69
- package/src/routes/dzimages.ts +0 -9
- package/src/routes/errorResponse.ts +0 -6
- package/src/routes/filter.gdc.ts +0 -15
- package/src/routes/gdc.maf.ts +0 -41
- package/src/routes/gdc.mafBuild.ts +0 -13
- package/src/routes/gdc.topMutatedGenes.ts +0 -25
- package/src/routes/genelookup.ts +0 -10
- package/src/routes/genesetEnrichment.ts +0 -46
- package/src/routes/genesetOverrepresentation.ts +0 -36
- package/src/routes/healthcheck.ts +0 -57
- package/src/routes/hicdata.ts +0 -37
- package/src/routes/hicgenome.ts +0 -22
- package/src/routes/hicstat.ts +0 -45
- package/src/routes/sampledzimages.ts +0 -1
- package/src/routes/samplewsimages.ts +0 -15
- package/src/routes/termdb.DE.ts +0 -44
- package/src/routes/termdb.boxplot.ts +0 -49
- package/src/routes/termdb.categories.ts +0 -26
- package/src/routes/termdb.cluster.ts +0 -86
- package/src/routes/termdb.getSampleImages.ts +0 -14
- package/src/routes/termdb.getTopTermsByType.ts +0 -21
- package/src/routes/termdb.getdescrstats.ts +0 -31
- package/src/routes/termdb.getnumericcategories.ts +0 -21
- package/src/routes/termdb.getpercentile.ts +0 -17
- package/src/routes/termdb.getrootterm.ts +0 -22
- package/src/routes/termdb.gettermchildren.ts +0 -21
- package/src/routes/termdb.singleSampleMutation.ts +0 -18
- package/src/routes/termdb.singlecellDEgenes.ts +0 -30
- package/src/routes/termdb.singlecellData.ts +0 -58
- package/src/routes/termdb.singlecellSamples.ts +0 -35
- package/src/routes/termdb.termsbyids.ts +0 -15
- package/src/routes/termdb.topVariablyExpressedGenes.ts +0 -45
- package/src/routes/termdb.violin.ts +0 -74
- package/src/routes/wsimages.ts +0 -12
- package/src/terms/categorical.ts +0 -106
- package/src/terms/condition.ts +0 -55
- package/src/terms/geneExpression.ts +0 -32
- package/src/terms/geneVariant.ts +0 -51
- package/src/terms/metaboliteIntensity.ts +0 -31
- package/src/terms/numeric.ts +0 -253
- package/src/terms/q.ts +0 -38
- package/src/terms/samplelst.ts +0 -41
- package/src/terms/singleCellCellType.ts +0 -22
- package/src/terms/singleCellGeneExpression.ts +0 -28
- package/src/terms/snp.ts +0 -28
- package/src/terms/snps.ts +0 -110
- package/src/terms/term.ts +0 -184
- package/src/terms/tw.ts +0 -38
- package/src/terms/updated-types.ts +0 -9
- package/src/termsetting.ts +0 -197
- package/src/test/numeric.type.spec.ts +0 -275
- package/src/typedoc.js +0 -30
- package/src/vocab.ts +0 -37
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
const termdbCategoriesPayload = {
|
|
2
|
+
request: {
|
|
3
|
+
typeId: "CategoriesRequest"
|
|
4
|
+
},
|
|
5
|
+
response: {
|
|
6
|
+
typeId: "CategoriesResponse"
|
|
7
|
+
},
|
|
8
|
+
examples: [
|
|
9
|
+
{
|
|
10
|
+
request: {
|
|
11
|
+
body: {
|
|
12
|
+
genome: "hg38-test",
|
|
13
|
+
dslabel: "TermdbTest",
|
|
14
|
+
embedder: "localhost",
|
|
15
|
+
term: { id: "diaggrp" },
|
|
16
|
+
filter: {
|
|
17
|
+
type: "tvslst",
|
|
18
|
+
in: true,
|
|
19
|
+
join: "",
|
|
20
|
+
lst: [
|
|
21
|
+
{
|
|
22
|
+
tag: "cohortFilter",
|
|
23
|
+
type: "tvs",
|
|
24
|
+
tvs: {
|
|
25
|
+
term: {
|
|
26
|
+
name: "Cohort",
|
|
27
|
+
type: "categorical",
|
|
28
|
+
values: { ABC: { label: "ABC" }, XYZ: { label: "XYZ" } },
|
|
29
|
+
id: "subcohort",
|
|
30
|
+
isleaf: false,
|
|
31
|
+
groupsetting: { disabled: true }
|
|
32
|
+
},
|
|
33
|
+
values: [{ key: "ABC", label: "ABC" }]
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
]
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
},
|
|
40
|
+
response: {
|
|
41
|
+
header: { status: 200 }
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
]
|
|
45
|
+
};
|
|
46
|
+
export {
|
|
47
|
+
termdbCategoriesPayload
|
|
48
|
+
};
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
const descrStatsPayload = {
|
|
2
|
+
request: {
|
|
3
|
+
typeId: "DescrStatsRequest"
|
|
4
|
+
},
|
|
5
|
+
response: {
|
|
6
|
+
typeId: "DescrStatsResponse"
|
|
7
|
+
},
|
|
8
|
+
examples: [
|
|
9
|
+
{
|
|
10
|
+
request: {
|
|
11
|
+
body: {
|
|
12
|
+
genome: "hg38-test",
|
|
13
|
+
dslabel: "TermdbTest",
|
|
14
|
+
embedder: "localhost",
|
|
15
|
+
tw: { term: { id: "hrtavg" }, q: { mode: "continuous" } },
|
|
16
|
+
filter: {
|
|
17
|
+
type: "tvslst",
|
|
18
|
+
in: true,
|
|
19
|
+
join: "",
|
|
20
|
+
lst: [
|
|
21
|
+
{
|
|
22
|
+
tag: "cohortFilter",
|
|
23
|
+
type: "tvs",
|
|
24
|
+
tvs: {
|
|
25
|
+
term: {
|
|
26
|
+
name: "Cohort",
|
|
27
|
+
type: "categorical",
|
|
28
|
+
values: { ABC: { label: "ABC" }, XYZ: { label: "XYZ" } },
|
|
29
|
+
id: "subcohort",
|
|
30
|
+
isleaf: false,
|
|
31
|
+
groupsetting: { disabled: true }
|
|
32
|
+
},
|
|
33
|
+
values: [{ key: "ABC", label: "ABC" }]
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
]
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
},
|
|
40
|
+
response: {
|
|
41
|
+
header: { status: 200 }
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
]
|
|
45
|
+
};
|
|
46
|
+
export {
|
|
47
|
+
descrStatsPayload
|
|
48
|
+
};
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
const percentilePayload = {
|
|
2
|
+
request: {
|
|
3
|
+
typeId: "PercentileRequest"
|
|
4
|
+
},
|
|
5
|
+
response: {
|
|
6
|
+
typeId: "PercentileResponse"
|
|
7
|
+
},
|
|
8
|
+
examples: [
|
|
9
|
+
{
|
|
10
|
+
request: {
|
|
11
|
+
body: {
|
|
12
|
+
genome: "hg38-test",
|
|
13
|
+
dslabel: "TermdbTest",
|
|
14
|
+
embedder: "localhost",
|
|
15
|
+
getpercentile: [50],
|
|
16
|
+
tid: "agedx",
|
|
17
|
+
filter: {
|
|
18
|
+
type: "tvslst",
|
|
19
|
+
in: true,
|
|
20
|
+
join: "",
|
|
21
|
+
lst: [
|
|
22
|
+
{
|
|
23
|
+
tag: "cohortFilter",
|
|
24
|
+
type: "tvs",
|
|
25
|
+
tvs: {
|
|
26
|
+
term: {
|
|
27
|
+
name: "Cohort",
|
|
28
|
+
type: "categorical",
|
|
29
|
+
values: { ABC: { label: "ABC" }, XYZ: { label: "XYZ" } },
|
|
30
|
+
id: "subcohort",
|
|
31
|
+
isleaf: false,
|
|
32
|
+
groupsetting: { disabled: true }
|
|
33
|
+
},
|
|
34
|
+
values: [{ key: "ABC", label: "ABC" }]
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
]
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
},
|
|
41
|
+
response: {
|
|
42
|
+
header: { status: 200 }
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
]
|
|
46
|
+
};
|
|
47
|
+
export {
|
|
48
|
+
percentilePayload
|
|
49
|
+
};
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
const rootTermPayload = {
|
|
2
|
+
request: {
|
|
3
|
+
typeId: "RootTermRequest"
|
|
4
|
+
},
|
|
5
|
+
response: {
|
|
6
|
+
typeId: "RootTermResponse"
|
|
7
|
+
},
|
|
8
|
+
examples: [
|
|
9
|
+
{
|
|
10
|
+
request: {
|
|
11
|
+
body: {
|
|
12
|
+
genome: "hg38-test",
|
|
13
|
+
dslabel: "TermdbTest",
|
|
14
|
+
embedder: "localhost",
|
|
15
|
+
default_rootterm: 1,
|
|
16
|
+
cohortValues: "ABC"
|
|
17
|
+
}
|
|
18
|
+
},
|
|
19
|
+
response: {
|
|
20
|
+
header: { status: 200 }
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
]
|
|
24
|
+
};
|
|
25
|
+
export {
|
|
26
|
+
rootTermPayload
|
|
27
|
+
};
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
const termChildrenPayload = {
|
|
2
|
+
request: {
|
|
3
|
+
typeId: "TermChildrenRequest"
|
|
4
|
+
},
|
|
5
|
+
response: {
|
|
6
|
+
typeId: "TermChildrenResponse"
|
|
7
|
+
},
|
|
8
|
+
examples: [
|
|
9
|
+
{
|
|
10
|
+
request: {
|
|
11
|
+
body: {
|
|
12
|
+
genome: "hg38-test",
|
|
13
|
+
dslabel: "TermdbTest",
|
|
14
|
+
embedder: "localhost",
|
|
15
|
+
get_children: 1,
|
|
16
|
+
cohortValues: "ABC",
|
|
17
|
+
tid: "GO:0000001"
|
|
18
|
+
}
|
|
19
|
+
},
|
|
20
|
+
response: {
|
|
21
|
+
header: { status: 200 }
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
]
|
|
25
|
+
};
|
|
26
|
+
export {
|
|
27
|
+
termChildrenPayload
|
|
28
|
+
};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
const termdbTopVariablyExpressedGenesPayload = {
|
|
2
|
+
request: {
|
|
3
|
+
typeId: "TermdbTopVariablyExpressedGenesRequest"
|
|
4
|
+
},
|
|
5
|
+
response: {
|
|
6
|
+
typeId: "TermdbTopVariablyExpressedGenesResponse"
|
|
7
|
+
}
|
|
8
|
+
// examples: []
|
|
9
|
+
};
|
|
10
|
+
export {
|
|
11
|
+
termdbTopVariablyExpressedGenesPayload
|
|
12
|
+
};
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
const violinPayload = {
|
|
2
|
+
request: {
|
|
3
|
+
typeId: "ViolinRequest"
|
|
4
|
+
},
|
|
5
|
+
response: {
|
|
6
|
+
typeId: "ViolinResponse"
|
|
7
|
+
},
|
|
8
|
+
examples: [
|
|
9
|
+
{
|
|
10
|
+
request: {
|
|
11
|
+
body: {
|
|
12
|
+
genome: "hg38-test",
|
|
13
|
+
dslabel: "TermdbTest",
|
|
14
|
+
embedder: "localhost",
|
|
15
|
+
devicePixelRatio: 2.200000047683716,
|
|
16
|
+
maxThickness: 150,
|
|
17
|
+
screenThickness: 1218,
|
|
18
|
+
filter: {
|
|
19
|
+
type: "tvslst",
|
|
20
|
+
in: true,
|
|
21
|
+
join: "",
|
|
22
|
+
lst: [
|
|
23
|
+
{
|
|
24
|
+
tag: "cohortFilter",
|
|
25
|
+
type: "tvs",
|
|
26
|
+
tvs: { term: { id: "subcohort", type: "categorical" }, values: [{ key: "ABC", label: "ABC" }] }
|
|
27
|
+
}
|
|
28
|
+
]
|
|
29
|
+
},
|
|
30
|
+
svgw: 227.27272234672367,
|
|
31
|
+
orientation: "horizontal",
|
|
32
|
+
datasymbol: "bean",
|
|
33
|
+
radius: 5,
|
|
34
|
+
strokeWidth: 0.2,
|
|
35
|
+
axisHeight: 60,
|
|
36
|
+
rightMargin: 50,
|
|
37
|
+
unit: "abs",
|
|
38
|
+
termid: "agedx"
|
|
39
|
+
}
|
|
40
|
+
},
|
|
41
|
+
response: {
|
|
42
|
+
header: { status: 200 }
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
]
|
|
46
|
+
};
|
|
47
|
+
export {
|
|
48
|
+
violinPayload
|
|
49
|
+
};
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
package/src/terms/q.js
ADDED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
package/src/terms/snp.js
ADDED
|
File without changes
|
|
File without changes
|
|
File without changes
|
package/src/terms/tw.js
ADDED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,117 @@
|
|
|
1
|
+
{
|
|
2
|
+
const valid = {
|
|
3
|
+
type: "float",
|
|
4
|
+
id: "someid",
|
|
5
|
+
name: "Some Dosage",
|
|
6
|
+
bins: {
|
|
7
|
+
default: {
|
|
8
|
+
type: "regular-bin",
|
|
9
|
+
bin_size: 1,
|
|
10
|
+
first_bin: {
|
|
11
|
+
startunbounded: true,
|
|
12
|
+
stop: 1
|
|
13
|
+
}
|
|
14
|
+
},
|
|
15
|
+
less: {
|
|
16
|
+
type: "custom-bin",
|
|
17
|
+
lst: [{ start: 0, stop: 1 }]
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
};
|
|
21
|
+
const A = { name: "test", type: "categorical" };
|
|
22
|
+
const B = { type: "integer" };
|
|
23
|
+
const C = {
|
|
24
|
+
// @ts-expect-error, should be string
|
|
25
|
+
name: 7,
|
|
26
|
+
type: "integer",
|
|
27
|
+
bins: {
|
|
28
|
+
default: {
|
|
29
|
+
type: "regular-bin",
|
|
30
|
+
bin_size: 1,
|
|
31
|
+
// tsc can detect type errors for deeply nested property values
|
|
32
|
+
// @ts-expect-error, does not match either StartUnboundedBin | FullyBoundedBin
|
|
33
|
+
first_bin: {
|
|
34
|
+
stop: 1
|
|
35
|
+
}
|
|
36
|
+
},
|
|
37
|
+
less: {
|
|
38
|
+
type: "custom-bin",
|
|
39
|
+
// @ts-expect-error, empty lst array
|
|
40
|
+
lst: []
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
};
|
|
44
|
+
}
|
|
45
|
+
{
|
|
46
|
+
const A = {
|
|
47
|
+
startunbounded: true,
|
|
48
|
+
startinclusive: true,
|
|
49
|
+
start: 0,
|
|
50
|
+
stop: 1,
|
|
51
|
+
stopinclusive: true,
|
|
52
|
+
stopunbounded: true
|
|
53
|
+
};
|
|
54
|
+
const B = {};
|
|
55
|
+
B.extraProp = "test";
|
|
56
|
+
}
|
|
57
|
+
{
|
|
58
|
+
const A = {
|
|
59
|
+
startunbounded: true,
|
|
60
|
+
stop: 1
|
|
61
|
+
};
|
|
62
|
+
const B = { startunbounded: true, start: 0, stop: 1 };
|
|
63
|
+
const C = { startunbounded: true };
|
|
64
|
+
const D = { startunbounded: true, start: 0, stop: 1, stopunbounded: true };
|
|
65
|
+
const E = {};
|
|
66
|
+
E.extraProp = "test";
|
|
67
|
+
}
|
|
68
|
+
{
|
|
69
|
+
const A = {
|
|
70
|
+
stopunbounded: true,
|
|
71
|
+
start: 0
|
|
72
|
+
};
|
|
73
|
+
const B = { stopunbounded: true, start: 0, stop: 1 };
|
|
74
|
+
const C = { stopunbounded: true };
|
|
75
|
+
const D = { startunbounded: true, start: 0, stop: 1, stopunbounded: true };
|
|
76
|
+
}
|
|
77
|
+
{
|
|
78
|
+
const A = {
|
|
79
|
+
startinclusive: true,
|
|
80
|
+
start: 0,
|
|
81
|
+
stop: 1
|
|
82
|
+
};
|
|
83
|
+
const B = { stop: 1 };
|
|
84
|
+
const C = { start: 0 };
|
|
85
|
+
}
|
|
86
|
+
const handlers = {
|
|
87
|
+
startUnbounded(bin) {
|
|
88
|
+
console.log(bin);
|
|
89
|
+
},
|
|
90
|
+
fullyBounded(bin) {
|
|
91
|
+
console.log(bin);
|
|
92
|
+
},
|
|
93
|
+
stopUnbounded(bin) {
|
|
94
|
+
console.log(bin);
|
|
95
|
+
}
|
|
96
|
+
};
|
|
97
|
+
function correctlyTypedProcessBin(bin) {
|
|
98
|
+
if (bin.startunbounded)
|
|
99
|
+
handlers.startUnbounded(bin);
|
|
100
|
+
else if (bin.stopunbounded)
|
|
101
|
+
handlers.stopUnbounded(bin);
|
|
102
|
+
else
|
|
103
|
+
handlers.fullyBounded(bin);
|
|
104
|
+
}
|
|
105
|
+
function incorrectProcessBin(bin) {
|
|
106
|
+
if (bin.startunbounded)
|
|
107
|
+
handlers.startUnbounded(bin);
|
|
108
|
+
else if (bin.stopunbounded)
|
|
109
|
+
handlers.stopUnbounded(bin);
|
|
110
|
+
else {
|
|
111
|
+
handlers.startUnbounded(bin);
|
|
112
|
+
handlers.stopUnbounded(bin);
|
|
113
|
+
handlers.fullyBounded(bin);
|
|
114
|
+
handlers.fullyBounded(bin);
|
|
115
|
+
handlers.fullyBounded(bin);
|
|
116
|
+
}
|
|
117
|
+
}
|
package/src/vocab.js
ADDED
|
File without changes
|