@vitessce/statistical-plots 3.5.7 → 3.5.8
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/{deflate-287e693d.js → deflate-1679ef33.js} +1 -1
- package/dist/{index-1f1b6355.js → index-0f4fe21d.js} +2065 -1061
- package/dist/index.js +9 -6
- package/dist/{jpeg-1b2c1d25.js → jpeg-280f0ee1.js} +1 -1
- package/dist/{lerc-4f010cd7.js → lerc-12264a36.js} +1 -1
- package/dist/{lzw-e60fb582.js → lzw-70f852cc.js} +1 -1
- package/dist/{packbits-a8bfe098.js → packbits-393c67b2.js} +1 -1
- package/dist/{raw-01dff90e.js → raw-d8d7ab7f.js} +1 -1
- package/dist/{webimage-6b926ce3.js → webimage-5d24a8e2.js} +1 -1
- package/dist-tsc/CellSetCompositionBarPlot.d.ts +5 -0
- package/dist-tsc/CellSetCompositionBarPlot.d.ts.map +1 -0
- package/dist-tsc/CellSetCompositionBarPlot.js +166 -0
- package/dist-tsc/CellSetCompositionBarPlotSubscriber.d.ts +2 -0
- package/dist-tsc/CellSetCompositionBarPlotSubscriber.d.ts.map +1 -0
- package/dist-tsc/CellSetCompositionBarPlotSubscriber.js +40 -0
- package/dist-tsc/FeatureSetEnrichmentBarPlot.d.ts +5 -0
- package/dist-tsc/FeatureSetEnrichmentBarPlot.d.ts.map +1 -0
- package/dist-tsc/FeatureSetEnrichmentBarPlot.js +164 -0
- package/dist-tsc/FeatureSetEnrichmentBarPlotSubscriber.d.ts +2 -0
- package/dist-tsc/FeatureSetEnrichmentBarPlotSubscriber.d.ts.map +1 -0
- package/dist-tsc/FeatureSetEnrichmentBarPlotSubscriber.js +51 -0
- package/dist-tsc/Treemap.d.ts.map +1 -1
- package/dist-tsc/Treemap.js +2 -12
- package/dist-tsc/TreemapSubscriber.d.ts.map +1 -1
- package/dist-tsc/TreemapSubscriber.js +1 -0
- package/dist-tsc/VolcanoPlot.d.ts +2 -0
- package/dist-tsc/VolcanoPlot.d.ts.map +1 -0
- package/dist-tsc/VolcanoPlot.js +230 -0
- package/dist-tsc/VolcanoPlotOptions.d.ts +2 -0
- package/dist-tsc/VolcanoPlotOptions.d.ts.map +1 -0
- package/dist-tsc/VolcanoPlotOptions.js +23 -0
- package/dist-tsc/VolcanoPlotSubscriber.d.ts +2 -0
- package/dist-tsc/VolcanoPlotSubscriber.d.ts.map +1 -0
- package/dist-tsc/VolcanoPlotSubscriber.js +33 -0
- package/dist-tsc/index.d.ts +3 -0
- package/dist-tsc/index.js +3 -0
- package/dist-tsc/utils.d.ts +9 -0
- package/dist-tsc/utils.d.ts.map +1 -0
- package/dist-tsc/utils.js +40 -0
- package/package.json +7 -7
- package/src/CellSetCompositionBarPlot.js +205 -0
- package/src/CellSetCompositionBarPlotSubscriber.js +151 -0
- package/src/FeatureSetEnrichmentBarPlot.js +203 -0
- package/src/FeatureSetEnrichmentBarPlotSubscriber.js +166 -0
- package/src/Treemap.js +2 -17
- package/src/TreemapSubscriber.js +1 -0
- package/src/VolcanoPlot.js +313 -0
- package/src/VolcanoPlotOptions.js +136 -0
- package/src/VolcanoPlotSubscriber.js +162 -0
- package/src/index.js +3 -0
- package/src/utils.js +47 -0
@@ -1,6 +1,6 @@
|
|
1
1
|
import * as React from "react";
|
2
2
|
import React__default, { useContext, useState, useRef, useCallback, useEffect, useMemo, Suspense } from "react";
|
3
|
-
import { usePlotOptionsStyles, OptionsContainer, OptionSelect, useLoaders, useCoordination, useGridItemSize, useFeatureSelection, useFeatureLabelsData, useExpandedFeatureLabelsMap, useObsFeatureMatrixIndices, useObsSetsData, useSampleSetsData, useSampleEdgesData, useReady, useUrls, TitleInfo, useObsFeatureMatrixData } from "@vitessce/vit-s";
|
3
|
+
import { usePlotOptionsStyles, OptionsContainer, OptionSelect, useLoaders, useCoordination, useGridItemSize, useFeatureSelection, useFeatureLabelsData, useExpandedFeatureLabelsMap, useObsFeatureMatrixIndices, useObsSetsData, useSampleSetsData, useSampleEdgesData, useReady, useUrls, TitleInfo, useObsFeatureMatrixData, useMatchingLoader, useColumnNameMapping, useFeatureStatsData, useObsSetStatsData, useAsyncFunction, useFeatureSetStatsData } from "@vitessce/vit-s";
|
4
4
|
import * as ReactDOM from "react-dom";
|
5
5
|
import ReactDOM__default from "react-dom";
|
6
6
|
function _mergeNamespaces(n2, m2) {
|
@@ -958,8 +958,13 @@ const ViewType$1 = {
|
|
958
958
|
FEATURE_VALUE_HISTOGRAM: "featureValueHistogram",
|
959
959
|
DOT_PLOT: "dotPlot",
|
960
960
|
FEATURE_BAR_PLOT: "featureBarPlot",
|
961
|
+
VOLCANO_PLOT: "volcanoPlot",
|
962
|
+
OBS_SET_COMPOSITION_BAR_PLOT: "obsSetCompositionBarPlot",
|
963
|
+
FEATURE_SET_ENRICHMENT_BAR_PLOT: "featureSetEnrichmentBarPlot",
|
961
964
|
BIOMARKER_SELECT: "biomarkerSelect",
|
965
|
+
COMPARATIVE_HEADING: "comparativeHeading",
|
962
966
|
LINK_CONTROLLER: "linkController",
|
967
|
+
NEUROGLANCER: "neuroglancer",
|
963
968
|
DUAL_SCATTERPLOT: "dualScatterplot",
|
964
969
|
TREEMAP: "treemap"
|
965
970
|
};
|
@@ -977,7 +982,33 @@ const DataType$2 = {
|
|
977
982
|
OBS_POINTS: "obsPoints",
|
978
983
|
OBS_LOCATIONS: "obsLocations",
|
979
984
|
SAMPLE_SETS: "sampleSets",
|
980
|
-
SAMPLE_EDGES: "sampleEdges"
|
985
|
+
SAMPLE_EDGES: "sampleEdges",
|
986
|
+
COMPARISON_METADATA: "comparisonMetadata",
|
987
|
+
FEATURE_STATS: "featureStats",
|
988
|
+
FEATURE_SET_STATS: "featureSetStats",
|
989
|
+
OBS_SET_STATS: "obsSetStats"
|
990
|
+
};
|
991
|
+
const AsyncFunctionType = {
|
992
|
+
// String input (rather than Node input)
|
993
|
+
AUTOCOMPLETE_FEATURE: "autocompleteFeature",
|
994
|
+
// (partial: string, targetModality: null | 'gene' | 'protein' | 'genomic-region' | 'cell-type') -> list of feature nodes
|
995
|
+
GET_ALTERNATIVE_TERMS: "getAlternativeTerms",
|
996
|
+
// (curieString) -> list of alternative curie strings
|
997
|
+
GET_TERM_MAPPING: "getTermMapping",
|
998
|
+
// (keyCuriePrefix, valueCuriePrefix) -> Record<curieString, curieString> for key to value
|
999
|
+
TRANSFORM_FEATURE: "transformFeature",
|
1000
|
+
// (featureNode, targetModality) -> list of feature nodes from target modality
|
1001
|
+
RELATED_FEATURES: "relatedFeatures",
|
1002
|
+
// (featureNode) -> list of related feature nodes
|
1003
|
+
FEATURE_TO_URL: "featureToUrl",
|
1004
|
+
// (featureNode) -> URL
|
1005
|
+
FEATURE_TO_INTERVAL: "featureToInterval",
|
1006
|
+
// (featureNode) -> genomic interval { chr, start, end }
|
1007
|
+
// Cell2Sentence/LLM-based?
|
1008
|
+
OBS_SET_TO_FEATURES: "obsSetToFeatures",
|
1009
|
+
// (cell type node) -> list of feature nodes
|
1010
|
+
FEATURES_TO_OBS_SET: "featuresToObsSet"
|
1011
|
+
// (list of feature nodes) -> cell type node
|
981
1012
|
};
|
982
1013
|
const FileType$1 = {
|
983
1014
|
// Joint file types
|
@@ -1016,6 +1047,10 @@ const FileType$1 = {
|
|
1016
1047
|
FEATURE_LABELS_ANNDATA_ZARR: "featureLabels.anndata.zarr",
|
1017
1048
|
SAMPLE_EDGES_ANNDATA_ZARR: "sampleEdges.anndata.zarr",
|
1018
1049
|
SAMPLE_SETS_ANNDATA_ZARR: "sampleSets.anndata.zarr",
|
1050
|
+
COMPARISON_METADATA_ANNDATA_ZARR: "comparisonMetadata.anndata.zarr",
|
1051
|
+
COMPARATIVE_FEATURE_STATS_ANNDATA_ZARR: "comparativeFeatureStats.anndata.zarr",
|
1052
|
+
COMPARATIVE_FEATURE_SET_STATS_ANNDATA_ZARR: "comparativeFeatureSetStats.anndata.zarr",
|
1053
|
+
COMPARATIVE_OBS_SET_STATS_ANNDATA_ZARR: "comparativeObsSetStats.anndata.zarr",
|
1019
1054
|
// AnnData - zipped
|
1020
1055
|
OBS_FEATURE_MATRIX_ANNDATA_ZARR_ZIP: "obsFeatureMatrix.anndata.zarr.zip",
|
1021
1056
|
OBS_FEATURE_COLUMNS_ANNDATA_ZARR_ZIP: "obsFeatureColumns.anndata.zarr.zip",
|
@@ -1029,6 +1064,10 @@ const FileType$1 = {
|
|
1029
1064
|
FEATURE_LABELS_ANNDATA_ZARR_ZIP: "featureLabels.anndata.zarr.zip",
|
1030
1065
|
SAMPLE_EDGES_ANNDATA_ZARR_ZIP: "sampleEdges.anndata.zarr.zip",
|
1031
1066
|
SAMPLE_SETS_ANNDATA_ZARR_ZIP: "sampleSets.anndata.zarr.zip",
|
1067
|
+
COMPARISON_METADATA_ANNDATA_ZARR_ZIP: "comparisonMetadata.anndata.zarr.zip",
|
1068
|
+
COMPARATIVE_FEATURE_STATS_ANNDATA_ZARR_ZIP: "comparativeFeatureStats.anndata.zarr.zip",
|
1069
|
+
COMPARATIVE_FEATURE_SET_STATS_ANNDATA_ZARR_ZIP: "comparativeFeatureSetStats.anndata.zarr.zip",
|
1070
|
+
COMPARATIVE_OBS_SET_STATS_ANNDATA_ZARR_ZIP: "comparativeObsSetStats.anndata.zarr.zip",
|
1032
1071
|
// AnnData - h5ad via reference spec
|
1033
1072
|
OBS_FEATURE_MATRIX_ANNDATA_H5AD: "obsFeatureMatrix.anndata.h5ad",
|
1034
1073
|
OBS_FEATURE_COLUMNS_ANNDATA_H5AD: "obsFeatureColumns.anndata.h5ad",
|
@@ -1042,6 +1081,10 @@ const FileType$1 = {
|
|
1042
1081
|
FEATURE_LABELS_ANNDATA_H5AD: "featureLabels.anndata.h5ad",
|
1043
1082
|
SAMPLE_EDGES_ANNDATA_H5AD: "sampleEdges.anndata.h5ad",
|
1044
1083
|
SAMPLE_SETS_ANNDATA_H5AD: "sampleSets.anndata.h5ad",
|
1084
|
+
COMPARISON_METADATA_ANNDATA_H5AD: "comparisonMetadata.anndata.h5ad",
|
1085
|
+
COMPARATIVE_FEATURE_STATS_ANNDATA_H5AD: "comparativeFeatureStats.anndata.h5ad",
|
1086
|
+
COMPARATIVE_FEATURE_SET_STATS_ANNDATA_H5AD: "comparativeFeatureSetStats.anndata.h5ad",
|
1087
|
+
COMPARATIVE_OBS_SET_STATS_ANNDATA_H5AD: "comparativeObsSetStats.anndata.h5ad",
|
1045
1088
|
// SpatialData
|
1046
1089
|
IMAGE_SPATIALDATA_ZARR: "image.spatialdata.zarr",
|
1047
1090
|
LABELS_SPATIALDATA_ZARR: "labels.spatialdata.zarr",
|
@@ -1240,6 +1283,11 @@ const CoordinationType$1 = {
|
|
1240
1283
|
EMBEDDING_CONTOUR_PERCENTILES: "embeddingContourPercentiles",
|
1241
1284
|
CONTOUR_COLOR_ENCODING: "contourColorEncoding",
|
1242
1285
|
CONTOUR_COLOR: "contourColor",
|
1286
|
+
// For volcano plot:
|
1287
|
+
FEATURE_POINT_SIGNIFICANCE_THRESHOLD: "featurePointSignificanceThreshold",
|
1288
|
+
FEATURE_LABEL_SIGNIFICANCE_THRESHOLD: "featureLabelSignificanceThreshold",
|
1289
|
+
FEATURE_POINT_FOLD_CHANGE_THRESHOLD: "featurePointFoldChangeThreshold",
|
1290
|
+
FEATURE_LABEL_FOLD_CHANGE_THRESHOLD: "featureLabelFoldChangeThreshold",
|
1243
1291
|
// Treemap
|
1244
1292
|
HIERARCHY_LEVELS: "hierarchyLevels"
|
1245
1293
|
};
|
@@ -1259,9 +1307,16 @@ const ViewHelpMapping = {
|
|
1259
1307
|
FEATURE_VALUE_HISTOGRAM: "The feature value histogram displays the distribution of values (e.g., expression) for the selected feature (e.g., gene).",
|
1260
1308
|
DOT_PLOT: "The dot plot displays summary information about expression of the selected features (e.g., genes) for each selected observation set (e.g., cell type).",
|
1261
1309
|
FEATURE_BAR_PLOT: "The feature bar plot displays one bar per observation (e.g., cell) along the x-axis, where the value of a selected feature (e.g., gene) is encoded along the y-axis.",
|
1262
|
-
|
1310
|
+
NEUROGLANCER: "The Neuroglancer view displays 3d meshes using Neuroglancer developed by Google.",
|
1311
|
+
TREEMAP: "The treemap provides an overview of the current state of sample-level or cell-level selection and filtering.",
|
1312
|
+
VOLCANO_PLOT: "The volcano plot displays differential expression results. Each data point represents a feature (as opposed to an observation).",
|
1313
|
+
OBS_SET_COMPOSITION_BAR_PLOT: "The set composition bar plot displays the results of a compositional analysis conducted using the scCODA method (Büttner et al. 2021 Nature Communications).",
|
1314
|
+
FEATURE_SET_ENRICHMENT_BAR_PLOT: "The feature set enrichment bar plot displays the results of a hypergeometric test applied to the differential expression test results to identify enriched pathway gene sets."
|
1263
1315
|
};
|
1264
1316
|
const COMPONENT_COORDINATION_TYPES = {
|
1317
|
+
[ViewType$1.NEUROGLANCER]: [
|
1318
|
+
CoordinationType$1.DATASET
|
1319
|
+
],
|
1265
1320
|
[ViewType$1.SCATTERPLOT]: [
|
1266
1321
|
CoordinationType$1.DATASET,
|
1267
1322
|
CoordinationType$1.OBS_TYPE,
|
@@ -1731,8 +1786,64 @@ const COMPONENT_COORDINATION_TYPES = {
|
|
1731
1786
|
CoordinationType$1.OBS_COLOR_ENCODING,
|
1732
1787
|
CoordinationType$1.ADDITIONAL_OBS_SETS
|
1733
1788
|
],
|
1789
|
+
[ViewType$1.VOLCANO_PLOT]: [
|
1790
|
+
CoordinationType$1.DATASET,
|
1791
|
+
CoordinationType$1.OBS_TYPE,
|
1792
|
+
CoordinationType$1.FEATURE_TYPE,
|
1793
|
+
CoordinationType$1.SAMPLE_TYPE,
|
1794
|
+
// For selection of case-control sets of samples:
|
1795
|
+
CoordinationType$1.SAMPLE_SET_SELECTION,
|
1796
|
+
// For selection of one-vs-others sets of observations:
|
1797
|
+
CoordinationType$1.OBS_SET_SELECTION,
|
1798
|
+
// TODO: CoordinationType.FEATURE_SET_SELECTION,
|
1799
|
+
// TODO: CoordinationType.FEATURE_SET_HIGHLIGHT,
|
1800
|
+
// TODO: CoordinationType.FEATURE_SET_COLOR,
|
1801
|
+
CoordinationType$1.FEATURE_HIGHLIGHT,
|
1802
|
+
CoordinationType$1.FEATURE_SELECTION,
|
1803
|
+
CoordinationType$1.FEATURE_VALUE_COLORMAP,
|
1804
|
+
CoordinationType$1.FEATURE_VALUE_COLORMAP_RANGE,
|
1805
|
+
// TODO: CoordinationType.FEATURE_COLOR_ENCODING,
|
1806
|
+
// TODO: CoordinationType.ADDITIONAL_FEATURE_SETS,
|
1807
|
+
CoordinationType$1.TOOLTIPS_VISIBLE,
|
1808
|
+
CoordinationType$1.ADDITIONAL_OBS_SETS,
|
1809
|
+
CoordinationType$1.OBS_SET_COLOR,
|
1810
|
+
CoordinationType$1.SAMPLE_SET_COLOR,
|
1811
|
+
CoordinationType$1.FEATURE_POINT_SIGNIFICANCE_THRESHOLD,
|
1812
|
+
CoordinationType$1.FEATURE_LABEL_SIGNIFICANCE_THRESHOLD,
|
1813
|
+
CoordinationType$1.FEATURE_POINT_FOLD_CHANGE_THRESHOLD,
|
1814
|
+
CoordinationType$1.FEATURE_LABEL_FOLD_CHANGE_THRESHOLD
|
1815
|
+
],
|
1816
|
+
[ViewType$1.OBS_SET_COMPOSITION_BAR_PLOT]: [
|
1817
|
+
CoordinationType$1.DATASET,
|
1818
|
+
CoordinationType$1.OBS_TYPE,
|
1819
|
+
CoordinationType$1.SAMPLE_TYPE,
|
1820
|
+
// For selection of case-control sets of samples:
|
1821
|
+
CoordinationType$1.SAMPLE_SET_SELECTION,
|
1822
|
+
// For selection of one-vs-others sets of observations:
|
1823
|
+
CoordinationType$1.OBS_SET_SELECTION,
|
1824
|
+
CoordinationType$1.ADDITIONAL_OBS_SETS,
|
1825
|
+
CoordinationType$1.OBS_SET_COLOR,
|
1826
|
+
CoordinationType$1.SAMPLE_SET_COLOR
|
1827
|
+
],
|
1828
|
+
[ViewType$1.FEATURE_SET_ENRICHMENT_BAR_PLOT]: [
|
1829
|
+
CoordinationType$1.DATASET,
|
1830
|
+
CoordinationType$1.OBS_TYPE,
|
1831
|
+
CoordinationType$1.FEATURE_TYPE,
|
1832
|
+
CoordinationType$1.SAMPLE_TYPE,
|
1833
|
+
// For selection of case-control sets of samples:
|
1834
|
+
CoordinationType$1.SAMPLE_SET_SELECTION,
|
1835
|
+
// For selection of one-vs-others sets of observations:
|
1836
|
+
CoordinationType$1.OBS_SET_SELECTION,
|
1837
|
+
CoordinationType$1.ADDITIONAL_OBS_SETS,
|
1838
|
+
CoordinationType$1.OBS_SET_COLOR,
|
1839
|
+
CoordinationType$1.SAMPLE_SET_COLOR,
|
1840
|
+
CoordinationType$1.FEATURE_SELECTION
|
1841
|
+
],
|
1734
1842
|
[ViewType$1.LINK_CONTROLLER]: [],
|
1735
1843
|
[ViewType$1.BIOMARKER_SELECT]: [
|
1844
|
+
CoordinationType$1.DATASET,
|
1845
|
+
CoordinationType$1.OBS_TYPE,
|
1846
|
+
CoordinationType$1.SAMPLE_TYPE,
|
1736
1847
|
CoordinationType$1.FEATURE_SELECTION,
|
1737
1848
|
CoordinationType$1.SAMPLE_SET_SELECTION,
|
1738
1849
|
CoordinationType$1.SAMPLE_SET_FILTER,
|
@@ -1740,6 +1851,16 @@ const COMPONENT_COORDINATION_TYPES = {
|
|
1740
1851
|
CoordinationType$1.OBS_SET_FILTER
|
1741
1852
|
// TODO: create coordination types for internal state of the biomarker selection view?
|
1742
1853
|
],
|
1854
|
+
[ViewType$1.COMPARATIVE_HEADING]: [
|
1855
|
+
CoordinationType$1.DATASET,
|
1856
|
+
CoordinationType$1.OBS_TYPE,
|
1857
|
+
CoordinationType$1.SAMPLE_TYPE,
|
1858
|
+
CoordinationType$1.FEATURE_SELECTION,
|
1859
|
+
CoordinationType$1.SAMPLE_SET_SELECTION,
|
1860
|
+
CoordinationType$1.SAMPLE_SET_FILTER,
|
1861
|
+
CoordinationType$1.OBS_SET_SELECTION,
|
1862
|
+
CoordinationType$1.OBS_SET_FILTER
|
1863
|
+
],
|
1743
1864
|
[ViewType$1.TREEMAP]: [
|
1744
1865
|
CoordinationType$1.DATASET,
|
1745
1866
|
CoordinationType$1.OBS_TYPE,
|
@@ -2578,7 +2699,7 @@ var reTrimStart = /^\s+/;
|
|
2578
2699
|
function baseTrim(string2) {
|
2579
2700
|
return string2 ? string2.slice(0, trimmedEndIndex(string2) + 1).replace(reTrimStart, "") : string2;
|
2580
2701
|
}
|
2581
|
-
function isObject$
|
2702
|
+
function isObject$6(value2) {
|
2582
2703
|
var type2 = typeof value2;
|
2583
2704
|
return value2 != null && (type2 == "object" || type2 == "function");
|
2584
2705
|
}
|
@@ -2594,9 +2715,9 @@ function toNumber$2(value2) {
|
|
2594
2715
|
if (isSymbol$1(value2)) {
|
2595
2716
|
return NAN$1;
|
2596
2717
|
}
|
2597
|
-
if (isObject$
|
2718
|
+
if (isObject$6(value2)) {
|
2598
2719
|
var other = typeof value2.valueOf == "function" ? value2.valueOf() : value2;
|
2599
|
-
value2 = isObject$
|
2720
|
+
value2 = isObject$6(other) ? other + "" : other;
|
2600
2721
|
}
|
2601
2722
|
if (typeof value2 != "string") {
|
2602
2723
|
return value2 === 0 ? value2 : +value2;
|
@@ -2618,8 +2739,8 @@ function toFinite(value2) {
|
|
2618
2739
|
return value2 === value2 ? value2 : 0;
|
2619
2740
|
}
|
2620
2741
|
var asyncTag = "[object AsyncFunction]", funcTag$2 = "[object Function]", genTag$1 = "[object GeneratorFunction]", proxyTag = "[object Proxy]";
|
2621
|
-
function isFunction$
|
2622
|
-
if (!isObject$
|
2742
|
+
function isFunction$5(value2) {
|
2743
|
+
if (!isObject$6(value2)) {
|
2623
2744
|
return false;
|
2624
2745
|
}
|
2625
2746
|
var tag = baseGetTag(value2);
|
@@ -2658,10 +2779,10 @@ var reIsNative = RegExp(
|
|
2658
2779
|
"^" + funcToString.call(hasOwnProperty$d).replace(reRegExpChar, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"
|
2659
2780
|
);
|
2660
2781
|
function baseIsNative(value2) {
|
2661
|
-
if (!isObject$
|
2782
|
+
if (!isObject$6(value2) || isMasked(value2)) {
|
2662
2783
|
return false;
|
2663
2784
|
}
|
2664
|
-
var pattern = isFunction$
|
2785
|
+
var pattern = isFunction$5(value2) ? reIsNative : reIsHostCtor;
|
2665
2786
|
return pattern.test(toSource(value2));
|
2666
2787
|
}
|
2667
2788
|
function getValue$2(object2, key2) {
|
@@ -2678,7 +2799,7 @@ var baseCreate = function() {
|
|
2678
2799
|
function object2() {
|
2679
2800
|
}
|
2680
2801
|
return function(proto) {
|
2681
|
-
if (!isObject$
|
2802
|
+
if (!isObject$6(proto)) {
|
2682
2803
|
return {};
|
2683
2804
|
}
|
2684
2805
|
if (objectCreate) {
|
@@ -2770,10 +2891,10 @@ function isLength(value2) {
|
|
2770
2891
|
return typeof value2 == "number" && value2 > -1 && value2 % 1 == 0 && value2 <= MAX_SAFE_INTEGER$4;
|
2771
2892
|
}
|
2772
2893
|
function isArrayLike(value2) {
|
2773
|
-
return value2 != null && isLength(value2.length) && !isFunction$
|
2894
|
+
return value2 != null && isLength(value2.length) && !isFunction$5(value2);
|
2774
2895
|
}
|
2775
2896
|
function isIterateeCall(value2, index2, object2) {
|
2776
|
-
if (!isObject$
|
2897
|
+
if (!isObject$6(object2)) {
|
2777
2898
|
return false;
|
2778
2899
|
}
|
2779
2900
|
var type2 = typeof index2;
|
@@ -2899,7 +3020,7 @@ function nativeKeysIn(object2) {
|
|
2899
3020
|
var objectProto$7 = Object.prototype;
|
2900
3021
|
var hasOwnProperty$8 = objectProto$7.hasOwnProperty;
|
2901
3022
|
function baseKeysIn(object2) {
|
2902
|
-
if (!isObject$
|
3023
|
+
if (!isObject$6(object2)) {
|
2903
3024
|
return nativeKeysIn(object2);
|
2904
3025
|
}
|
2905
3026
|
var isProto = isPrototype(object2), result = [];
|
@@ -3345,7 +3466,7 @@ function baseClone(value2, bitmask, customizer, key2, object2, stack2) {
|
|
3345
3466
|
if (result !== void 0) {
|
3346
3467
|
return result;
|
3347
3468
|
}
|
3348
|
-
if (!isObject$
|
3469
|
+
if (!isObject$6(value2)) {
|
3349
3470
|
return value2;
|
3350
3471
|
}
|
3351
3472
|
var isArr = isArray$5(value2);
|
@@ -3639,7 +3760,7 @@ function debounce$3(func, wait, options) {
|
|
3639
3760
|
throw new TypeError(FUNC_ERROR_TEXT$1);
|
3640
3761
|
}
|
3641
3762
|
wait = toNumber$2(wait) || 0;
|
3642
|
-
if (isObject$
|
3763
|
+
if (isObject$6(options)) {
|
3643
3764
|
leading = !!options.leading;
|
3644
3765
|
maxing = "maxWait" in options;
|
3645
3766
|
maxWait = maxing ? nativeMax$2(toNumber$2(options.maxWait) || 0, wait) : maxWait;
|
@@ -3742,8 +3863,8 @@ function createRange(fromRight) {
|
|
3742
3863
|
return baseRange(start, end, step, fromRight);
|
3743
3864
|
};
|
3744
3865
|
}
|
3745
|
-
var range$
|
3746
|
-
const range$
|
3866
|
+
var range$b = createRange();
|
3867
|
+
const range$c = range$b;
|
3747
3868
|
var earthRadius = 63710088e-1;
|
3748
3869
|
var factors = {
|
3749
3870
|
centimeters: earthRadius * 100,
|
@@ -3841,7 +3962,7 @@ function point$9(coordinates2, properties, options) {
|
|
3841
3962
|
if (coordinates2.length < 2) {
|
3842
3963
|
throw new Error("coordinates must be at least 2 numbers long");
|
3843
3964
|
}
|
3844
|
-
if (!isNumber$
|
3965
|
+
if (!isNumber$3(coordinates2[0]) || !isNumber$3(coordinates2[1])) {
|
3845
3966
|
throw new Error("coordinates must contain numbers");
|
3846
3967
|
}
|
3847
3968
|
var geom = {
|
@@ -4042,10 +4163,10 @@ function convertArea(area2, originalUnit, finalUnit) {
|
|
4042
4163
|
}
|
4043
4164
|
return area2 / startFactor * finalFactor;
|
4044
4165
|
}
|
4045
|
-
function isNumber$
|
4166
|
+
function isNumber$3(num) {
|
4046
4167
|
return !isNaN(num) && num !== null && !Array.isArray(num);
|
4047
4168
|
}
|
4048
|
-
function isObject$
|
4169
|
+
function isObject$5(input) {
|
4049
4170
|
return !!input && input.constructor === Object;
|
4050
4171
|
}
|
4051
4172
|
function validateBBox(bbox2) {
|
@@ -4059,7 +4180,7 @@ function validateBBox(bbox2) {
|
|
4059
4180
|
throw new Error("bbox must be an Array of 4 or 6 numbers");
|
4060
4181
|
}
|
4061
4182
|
bbox2.forEach(function(num) {
|
4062
|
-
if (!isNumber$
|
4183
|
+
if (!isNumber$3(num)) {
|
4063
4184
|
throw new Error("bbox must only contain numbers");
|
4064
4185
|
}
|
4065
4186
|
});
|
@@ -4085,8 +4206,8 @@ const es$7 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty
|
|
4085
4206
|
featureCollection: featureCollection$1,
|
4086
4207
|
geometry: geometry$1,
|
4087
4208
|
geometryCollection,
|
4088
|
-
isNumber: isNumber$
|
4089
|
-
isObject: isObject$
|
4209
|
+
isNumber: isNumber$3,
|
4210
|
+
isObject: isObject$5,
|
4090
4211
|
lengthToDegrees,
|
4091
4212
|
lengthToRadians,
|
4092
4213
|
lineString,
|
@@ -4528,7 +4649,7 @@ function lineReduce$1(geojson, callback, initialValue) {
|
|
4528
4649
|
}
|
4529
4650
|
function findSegment$1(geojson, options) {
|
4530
4651
|
options = options || {};
|
4531
|
-
if (!isObject$
|
4652
|
+
if (!isObject$5(options))
|
4532
4653
|
throw new Error("options is invalid");
|
4533
4654
|
var featureIndex = options.featureIndex || 0;
|
4534
4655
|
var multiFeatureIndex = options.multiFeatureIndex || 0;
|
@@ -4620,7 +4741,7 @@ function findSegment$1(geojson, options) {
|
|
4620
4741
|
}
|
4621
4742
|
function findPoint$1(geojson, options) {
|
4622
4743
|
options = options || {};
|
4623
|
-
if (!isObject$
|
4744
|
+
if (!isObject$5(options))
|
4624
4745
|
throw new Error("options is invalid");
|
4625
4746
|
var featureIndex = options.featureIndex || 0;
|
4626
4747
|
var multiFeatureIndex = options.multiFeatureIndex || 0;
|
@@ -9951,9 +10072,9 @@ var debug_1$1 = debug$6;
|
|
9951
10072
|
const re2 = exports2.re = [];
|
9952
10073
|
const src = exports2.src = [];
|
9953
10074
|
const t4 = exports2.t = {};
|
9954
|
-
let
|
10075
|
+
let R = 0;
|
9955
10076
|
const createToken = (name2, value2, isGlobal) => {
|
9956
|
-
const index2 =
|
10077
|
+
const index2 = R++;
|
9957
10078
|
debug2(name2, index2, value2);
|
9958
10079
|
t4[name2] = index2;
|
9959
10080
|
src[index2] = value2;
|
@@ -11094,11 +11215,11 @@ const forEachStep$1 = (self2, fn, node, thisp) => {
|
|
11094
11215
|
fn.call(thisp, hit2.value, hit2.key, self2);
|
11095
11216
|
};
|
11096
11217
|
var lruCache$2 = LRUCache$2;
|
11097
|
-
var range$
|
11218
|
+
var range$a;
|
11098
11219
|
var hasRequiredRange$1;
|
11099
11220
|
function requireRange$1() {
|
11100
11221
|
if (hasRequiredRange$1)
|
11101
|
-
return range$
|
11222
|
+
return range$a;
|
11102
11223
|
hasRequiredRange$1 = 1;
|
11103
11224
|
class Range2 {
|
11104
11225
|
constructor(range2, options) {
|
@@ -11223,7 +11344,7 @@ function requireRange$1() {
|
|
11223
11344
|
return false;
|
11224
11345
|
}
|
11225
11346
|
}
|
11226
|
-
range$
|
11347
|
+
range$a = Range2;
|
11227
11348
|
const LRU = lruCache$2;
|
11228
11349
|
const cache2 = new LRU({ max: 1e3 });
|
11229
11350
|
const parseOptions2 = parseOptions_1$1;
|
@@ -11454,7 +11575,7 @@ function requireRange$1() {
|
|
11454
11575
|
}
|
11455
11576
|
return true;
|
11456
11577
|
};
|
11457
|
-
return range$
|
11578
|
+
return range$a;
|
11458
11579
|
}
|
11459
11580
|
var comparator$2;
|
11460
11581
|
var hasRequiredComparator$1;
|
@@ -12279,6 +12400,42 @@ const annDataConvenienceObsEmbeddingItem = z.object({
|
|
12279
12400
|
dims: z.array(z.number()).optional(),
|
12280
12401
|
embeddingType: z.string()
|
12281
12402
|
});
|
12403
|
+
z.object({
|
12404
|
+
path: z.string().describe("Path to the comparison metadata, such as /uns/comparison_metadata")
|
12405
|
+
});
|
12406
|
+
z.object({
|
12407
|
+
// TODO: implement a featureStats.anndata.zarr loader
|
12408
|
+
// which does not depend on comparisonMetadata
|
12409
|
+
// (instead, would point directly to the root of
|
12410
|
+
// the dataframe containing a set of diff exp results)
|
12411
|
+
// path: z.string().describe('Path to the dataframe containing the results.'),
|
12412
|
+
metadataPath: z.string().describe("Path to the comparison metadata."),
|
12413
|
+
indexColumn: z.string().optional().describe("Provide a column to use for the feature index, if different than the default dataframe index."),
|
12414
|
+
pValueColumn: z.string(),
|
12415
|
+
foldChangeColumn: z.string(),
|
12416
|
+
pValueTransformation: z.enum(["minuslog10"]).optional(),
|
12417
|
+
pValueAdjusted: z.boolean().optional(),
|
12418
|
+
foldChangeTransformation: z.enum(["log2"]).optional()
|
12419
|
+
});
|
12420
|
+
z.object({
|
12421
|
+
metadataPath: z.string().describe("Path to the comparison metadata."),
|
12422
|
+
indexColumn: z.string().optional().describe("Provide a column to use for the feature set index, if different than the default dataframe index."),
|
12423
|
+
termColumn: z.string().optional(),
|
12424
|
+
pValueColumn: z.string(),
|
12425
|
+
pValueAdjusted: z.boolean().optional(),
|
12426
|
+
analysisType: z.string().optional().describe("Optionally, provide an analysis_type name. By default, pertpy_hypergeometric.")
|
12427
|
+
});
|
12428
|
+
z.object({
|
12429
|
+
metadataPath: z.string().describe("Path to the comparison metadata."),
|
12430
|
+
indexColumn: z.string().optional().describe("Provide a column to use for the obs set index, if different than the default dataframe index."),
|
12431
|
+
interceptExpectedSampleColumn: z.string().describe("If we had a new sample (with no active covariates) with a total number of cells equal to the mean sampling depth of the dataset, then this distribution over the cell types would be most likely."),
|
12432
|
+
effectExpectedSampleColumn: z.string().describe("If we had a new sample (with no active covariates) with a total number of cells equal to the mean sampling depth of the dataset, then this distribution over the cell types would be most likely."),
|
12433
|
+
foldChangeColumn: z.string().describe("The log-fold change is then calculated between this expected sample and the expected sample with no active covariates from the intercept section."),
|
12434
|
+
foldChangeTransformation: z.enum(["log2"]).optional(),
|
12435
|
+
isCredibleEffectColumn: z.string().describe("Column which annotates effects as being credible or not (boolean)."),
|
12436
|
+
covariateColumn: z.string().describe("Column which defines the covariate used in the analysis."),
|
12437
|
+
analysisType: z.string().optional().describe("Optionally, provide an analysis_type name. By default, sccoda_df.")
|
12438
|
+
});
|
12282
12439
|
const annDataObsLabels = annDataObs;
|
12283
12440
|
const annDataFeatureLabels = annDataObs;
|
12284
12441
|
const annDataSampleEdges = annDataObs;
|
@@ -12598,14 +12755,14 @@ var tinycolor$1 = { exports: {} };
|
|
12598
12755
|
},
|
12599
12756
|
getLuminance: function() {
|
12600
12757
|
var rgb2 = this.toRgb();
|
12601
|
-
var RsRGB, GsRGB, BsRGB,
|
12758
|
+
var RsRGB, GsRGB, BsRGB, R, G2, B2;
|
12602
12759
|
RsRGB = rgb2.r / 255;
|
12603
12760
|
GsRGB = rgb2.g / 255;
|
12604
12761
|
BsRGB = rgb2.b / 255;
|
12605
12762
|
if (RsRGB <= 0.03928) {
|
12606
|
-
|
12763
|
+
R = RsRGB / 12.92;
|
12607
12764
|
} else {
|
12608
|
-
|
12765
|
+
R = Math2.pow((RsRGB + 0.055) / 1.055, 2.4);
|
12609
12766
|
}
|
12610
12767
|
if (GsRGB <= 0.03928) {
|
12611
12768
|
G2 = GsRGB / 12.92;
|
@@ -12617,7 +12774,7 @@ var tinycolor$1 = { exports: {} };
|
|
12617
12774
|
} else {
|
12618
12775
|
B2 = Math2.pow((BsRGB + 0.055) / 1.055, 2.4);
|
12619
12776
|
}
|
12620
|
-
return 0.2126 *
|
12777
|
+
return 0.2126 * R + 0.7152 * G2 + 0.0722 * B2;
|
12621
12778
|
},
|
12622
12779
|
setAlpha: function(value2) {
|
12623
12780
|
this._a = boundAlpha(value2);
|
@@ -13697,7 +13854,7 @@ var json2csv_umd = { exports: {} };
|
|
13697
13854
|
}
|
13698
13855
|
this._maxListeners = this._maxListeners || void 0;
|
13699
13856
|
};
|
13700
|
-
EventEmitter2.prototype.setMaxListeners = function
|
13857
|
+
EventEmitter2.prototype.setMaxListeners = function setMaxListeners(n2) {
|
13701
13858
|
if (typeof n2 !== "number" || n2 < 0 || isNaN(n2))
|
13702
13859
|
throw new TypeError('"n" argument must be a positive number');
|
13703
13860
|
this._maxListeners = n2;
|
@@ -13708,7 +13865,7 @@ var json2csv_umd = { exports: {} };
|
|
13708
13865
|
return EventEmitter2.defaultMaxListeners;
|
13709
13866
|
return that._maxListeners;
|
13710
13867
|
}
|
13711
|
-
EventEmitter2.prototype.getMaxListeners = function
|
13868
|
+
EventEmitter2.prototype.getMaxListeners = function getMaxListeners() {
|
13712
13869
|
return $getMaxListeners(this);
|
13713
13870
|
};
|
13714
13871
|
function emitNone(handler, isFn, self2) {
|
@@ -13716,9 +13873,9 @@ var json2csv_umd = { exports: {} };
|
|
13716
13873
|
handler.call(self2);
|
13717
13874
|
else {
|
13718
13875
|
var len2 = handler.length;
|
13719
|
-
var
|
13876
|
+
var listeners = arrayClone(handler, len2);
|
13720
13877
|
for (var i2 = 0; i2 < len2; ++i2)
|
13721
|
-
|
13878
|
+
listeners[i2].call(self2);
|
13722
13879
|
}
|
13723
13880
|
}
|
13724
13881
|
function emitOne(handler, isFn, self2, arg1) {
|
@@ -13726,9 +13883,9 @@ var json2csv_umd = { exports: {} };
|
|
13726
13883
|
handler.call(self2, arg1);
|
13727
13884
|
else {
|
13728
13885
|
var len2 = handler.length;
|
13729
|
-
var
|
13886
|
+
var listeners = arrayClone(handler, len2);
|
13730
13887
|
for (var i2 = 0; i2 < len2; ++i2)
|
13731
|
-
|
13888
|
+
listeners[i2].call(self2, arg1);
|
13732
13889
|
}
|
13733
13890
|
}
|
13734
13891
|
function emitTwo(handler, isFn, self2, arg1, arg2) {
|
@@ -13736,9 +13893,9 @@ var json2csv_umd = { exports: {} };
|
|
13736
13893
|
handler.call(self2, arg1, arg2);
|
13737
13894
|
else {
|
13738
13895
|
var len2 = handler.length;
|
13739
|
-
var
|
13896
|
+
var listeners = arrayClone(handler, len2);
|
13740
13897
|
for (var i2 = 0; i2 < len2; ++i2)
|
13741
|
-
|
13898
|
+
listeners[i2].call(self2, arg1, arg2);
|
13742
13899
|
}
|
13743
13900
|
}
|
13744
13901
|
function emitThree(handler, isFn, self2, arg1, arg2, arg3) {
|
@@ -13746,9 +13903,9 @@ var json2csv_umd = { exports: {} };
|
|
13746
13903
|
handler.call(self2, arg1, arg2, arg3);
|
13747
13904
|
else {
|
13748
13905
|
var len2 = handler.length;
|
13749
|
-
var
|
13906
|
+
var listeners = arrayClone(handler, len2);
|
13750
13907
|
for (var i2 = 0; i2 < len2; ++i2)
|
13751
|
-
|
13908
|
+
listeners[i2].call(self2, arg1, arg2, arg3);
|
13752
13909
|
}
|
13753
13910
|
}
|
13754
13911
|
function emitMany(handler, isFn, self2, args) {
|
@@ -13756,12 +13913,12 @@ var json2csv_umd = { exports: {} };
|
|
13756
13913
|
handler.apply(self2, args);
|
13757
13914
|
else {
|
13758
13915
|
var len2 = handler.length;
|
13759
|
-
var
|
13916
|
+
var listeners = arrayClone(handler, len2);
|
13760
13917
|
for (var i2 = 0; i2 < len2; ++i2)
|
13761
|
-
|
13918
|
+
listeners[i2].apply(self2, args);
|
13762
13919
|
}
|
13763
13920
|
}
|
13764
|
-
EventEmitter2.prototype.emit = function
|
13921
|
+
EventEmitter2.prototype.emit = function emit2(type3) {
|
13765
13922
|
var er, handler, len2, args, i2, events2, domain3;
|
13766
13923
|
var doError = type3 === "error";
|
13767
13924
|
events2 = this._events;
|
@@ -13814,7 +13971,7 @@ var json2csv_umd = { exports: {} };
|
|
13814
13971
|
}
|
13815
13972
|
return true;
|
13816
13973
|
};
|
13817
|
-
function
|
13974
|
+
function _addListener(target2, type3, listener2, prepend) {
|
13818
13975
|
var m2;
|
13819
13976
|
var events2;
|
13820
13977
|
var existing;
|
@@ -13866,14 +14023,14 @@ var json2csv_umd = { exports: {} };
|
|
13866
14023
|
function emitWarning(e3) {
|
13867
14024
|
typeof console.warn === "function" ? console.warn(e3) : console.log(e3);
|
13868
14025
|
}
|
13869
|
-
EventEmitter2.prototype.addListener = function
|
13870
|
-
return
|
14026
|
+
EventEmitter2.prototype.addListener = function addListener(type3, listener2) {
|
14027
|
+
return _addListener(this, type3, listener2, false);
|
13871
14028
|
};
|
13872
14029
|
EventEmitter2.prototype.on = EventEmitter2.prototype.addListener;
|
13873
|
-
EventEmitter2.prototype.prependListener = function
|
13874
|
-
return
|
14030
|
+
EventEmitter2.prototype.prependListener = function prependListener2(type3, listener2) {
|
14031
|
+
return _addListener(this, type3, listener2, true);
|
13875
14032
|
};
|
13876
|
-
function
|
14033
|
+
function _onceWrap(target2, type3, listener2) {
|
13877
14034
|
var fired = false;
|
13878
14035
|
function g2() {
|
13879
14036
|
target2.removeListener(type3, g2);
|
@@ -13885,19 +14042,19 @@ var json2csv_umd = { exports: {} };
|
|
13885
14042
|
g2.listener = listener2;
|
13886
14043
|
return g2;
|
13887
14044
|
}
|
13888
|
-
EventEmitter2.prototype.once = function
|
14045
|
+
EventEmitter2.prototype.once = function once(type3, listener2) {
|
13889
14046
|
if (typeof listener2 !== "function")
|
13890
14047
|
throw new TypeError('"listener" argument must be a function');
|
13891
|
-
this.on(type3,
|
14048
|
+
this.on(type3, _onceWrap(this, type3, listener2));
|
13892
14049
|
return this;
|
13893
14050
|
};
|
13894
|
-
EventEmitter2.prototype.prependOnceListener = function
|
14051
|
+
EventEmitter2.prototype.prependOnceListener = function prependOnceListener(type3, listener2) {
|
13895
14052
|
if (typeof listener2 !== "function")
|
13896
14053
|
throw new TypeError('"listener" argument must be a function');
|
13897
|
-
this.prependListener(type3,
|
14054
|
+
this.prependListener(type3, _onceWrap(this, type3, listener2));
|
13898
14055
|
return this;
|
13899
14056
|
};
|
13900
|
-
EventEmitter2.prototype.removeListener = function
|
14057
|
+
EventEmitter2.prototype.removeListener = function removeListener(type3, listener2) {
|
13901
14058
|
var list, events2, position2, i2, originalListener;
|
13902
14059
|
if (typeof listener2 !== "function")
|
13903
14060
|
throw new TypeError('"listener" argument must be a function');
|
@@ -13935,15 +14092,15 @@ var json2csv_umd = { exports: {} };
|
|
13935
14092
|
delete events2[type3];
|
13936
14093
|
}
|
13937
14094
|
} else {
|
13938
|
-
|
14095
|
+
spliceOne(list, position2);
|
13939
14096
|
}
|
13940
14097
|
if (events2.removeListener)
|
13941
14098
|
this.emit("removeListener", type3, originalListener || listener2);
|
13942
14099
|
}
|
13943
14100
|
return this;
|
13944
14101
|
};
|
13945
|
-
EventEmitter2.prototype.removeAllListeners = function
|
13946
|
-
var
|
14102
|
+
EventEmitter2.prototype.removeAllListeners = function removeAllListeners(type3) {
|
14103
|
+
var listeners, events2;
|
13947
14104
|
events2 = this._events;
|
13948
14105
|
if (!events2)
|
13949
14106
|
return this;
|
@@ -13972,17 +14129,17 @@ var json2csv_umd = { exports: {} };
|
|
13972
14129
|
this._eventsCount = 0;
|
13973
14130
|
return this;
|
13974
14131
|
}
|
13975
|
-
|
13976
|
-
if (typeof
|
13977
|
-
this.removeListener(type3,
|
13978
|
-
} else if (
|
14132
|
+
listeners = events2[type3];
|
14133
|
+
if (typeof listeners === "function") {
|
14134
|
+
this.removeListener(type3, listeners);
|
14135
|
+
} else if (listeners) {
|
13979
14136
|
do {
|
13980
|
-
this.removeListener(type3,
|
13981
|
-
} while (
|
14137
|
+
this.removeListener(type3, listeners[listeners.length - 1]);
|
14138
|
+
} while (listeners[0]);
|
13982
14139
|
}
|
13983
14140
|
return this;
|
13984
14141
|
};
|
13985
|
-
EventEmitter2.prototype.listeners = function
|
14142
|
+
EventEmitter2.prototype.listeners = function listeners(type3) {
|
13986
14143
|
var evlistener;
|
13987
14144
|
var ret;
|
13988
14145
|
var events2 = this._events;
|
@@ -13995,7 +14152,7 @@ var json2csv_umd = { exports: {} };
|
|
13995
14152
|
else if (typeof evlistener === "function")
|
13996
14153
|
ret = [evlistener.listener || evlistener];
|
13997
14154
|
else
|
13998
|
-
ret =
|
14155
|
+
ret = unwrapListeners(evlistener);
|
13999
14156
|
}
|
14000
14157
|
return ret;
|
14001
14158
|
};
|
@@ -14003,11 +14160,11 @@ var json2csv_umd = { exports: {} };
|
|
14003
14160
|
if (typeof emitter.listenerCount === "function") {
|
14004
14161
|
return emitter.listenerCount(type3);
|
14005
14162
|
} else {
|
14006
|
-
return
|
14163
|
+
return listenerCount.call(emitter, type3);
|
14007
14164
|
}
|
14008
14165
|
};
|
14009
|
-
EventEmitter2.prototype.listenerCount =
|
14010
|
-
function
|
14166
|
+
EventEmitter2.prototype.listenerCount = listenerCount;
|
14167
|
+
function listenerCount(type3) {
|
14011
14168
|
var events2 = this._events;
|
14012
14169
|
if (events2) {
|
14013
14170
|
var evlistener = events2[type3];
|
@@ -14019,21 +14176,21 @@ var json2csv_umd = { exports: {} };
|
|
14019
14176
|
}
|
14020
14177
|
return 0;
|
14021
14178
|
}
|
14022
|
-
EventEmitter2.prototype.eventNames = function
|
14179
|
+
EventEmitter2.prototype.eventNames = function eventNames() {
|
14023
14180
|
return this._eventsCount > 0 ? Reflect.ownKeys(this._events) : [];
|
14024
14181
|
};
|
14025
|
-
function
|
14182
|
+
function spliceOne(list, index2) {
|
14026
14183
|
for (var i2 = index2, k = i2 + 1, n2 = list.length; k < n2; i2 += 1, k += 1)
|
14027
14184
|
list[i2] = list[k];
|
14028
14185
|
list.pop();
|
14029
14186
|
}
|
14030
|
-
function
|
14187
|
+
function arrayClone(arr, i2) {
|
14031
14188
|
var copy2 = new Array(i2);
|
14032
14189
|
while (i2--)
|
14033
14190
|
copy2[i2] = arr[i2];
|
14034
14191
|
return copy2;
|
14035
14192
|
}
|
14036
|
-
function
|
14193
|
+
function unwrapListeners(arr) {
|
14037
14194
|
var ret = new Array(arr.length);
|
14038
14195
|
for (var i2 = 0; i2 < ret.length; ++i2) {
|
14039
14196
|
ret[i2] = arr[i2].listener || arr[i2];
|
@@ -15825,7 +15982,7 @@ var json2csv_umd = { exports: {} };
|
|
15825
15982
|
return str;
|
15826
15983
|
}
|
15827
15984
|
function deprecate(fn, msg) {
|
15828
|
-
if (
|
15985
|
+
if (isUndefined2(global$1.process)) {
|
15829
15986
|
return function() {
|
15830
15987
|
return deprecate(fn, msg).apply(this, arguments);
|
15831
15988
|
};
|
@@ -15845,7 +16002,7 @@ var json2csv_umd = { exports: {} };
|
|
15845
16002
|
var debugs = {};
|
15846
16003
|
var debugEnviron;
|
15847
16004
|
function debuglog(set3) {
|
15848
|
-
if (
|
16005
|
+
if (isUndefined2(debugEnviron))
|
15849
16006
|
debugEnviron = "";
|
15850
16007
|
set3 = set3.toUpperCase();
|
15851
16008
|
if (!debugs[set3]) {
|
@@ -15876,13 +16033,13 @@ var json2csv_umd = { exports: {} };
|
|
15876
16033
|
} else if (opts2) {
|
15877
16034
|
_extend(ctx, opts2);
|
15878
16035
|
}
|
15879
|
-
if (
|
16036
|
+
if (isUndefined2(ctx.showHidden))
|
15880
16037
|
ctx.showHidden = false;
|
15881
|
-
if (
|
16038
|
+
if (isUndefined2(ctx.depth))
|
15882
16039
|
ctx.depth = 2;
|
15883
|
-
if (
|
16040
|
+
if (isUndefined2(ctx.colors))
|
15884
16041
|
ctx.colors = false;
|
15885
|
-
if (
|
16042
|
+
if (isUndefined2(ctx.customInspect))
|
15886
16043
|
ctx.customInspect = true;
|
15887
16044
|
if (ctx.colors)
|
15888
16045
|
ctx.stylize = stylizeWithColor;
|
@@ -16010,7 +16167,7 @@ var json2csv_umd = { exports: {} };
|
|
16010
16167
|
return reduceToSingleString(output2, base2, braces);
|
16011
16168
|
}
|
16012
16169
|
function formatPrimitive(ctx, value2) {
|
16013
|
-
if (
|
16170
|
+
if (isUndefined2(value2))
|
16014
16171
|
return ctx.stylize("undefined", "undefined");
|
16015
16172
|
if (isString2(value2)) {
|
16016
16173
|
var simple = "'" + JSON.stringify(value2).replace(/^"|"$/g, "").replace(/'/g, "\\'").replace(/\\"/g, '"') + "'";
|
@@ -16095,7 +16252,7 @@ var json2csv_umd = { exports: {} };
|
|
16095
16252
|
str = ctx.stylize("[Circular]", "special");
|
16096
16253
|
}
|
16097
16254
|
}
|
16098
|
-
if (
|
16255
|
+
if (isUndefined2(name2)) {
|
16099
16256
|
if (array2 && key2.match(/^\d+$/)) {
|
16100
16257
|
return str;
|
16101
16258
|
}
|
@@ -16136,7 +16293,7 @@ var json2csv_umd = { exports: {} };
|
|
16136
16293
|
function isString2(arg) {
|
16137
16294
|
return typeof arg === "string";
|
16138
16295
|
}
|
16139
|
-
function
|
16296
|
+
function isUndefined2(arg) {
|
16140
16297
|
return arg === void 0;
|
16141
16298
|
}
|
16142
16299
|
function isRegExp2(re2) {
|
@@ -16365,7 +16522,7 @@ var json2csv_umd = { exports: {} };
|
|
16365
16522
|
Readable.ReadableState = ReadableState;
|
16366
16523
|
var debug2 = debuglog("stream");
|
16367
16524
|
inherits$1(Readable, EventEmitter2);
|
16368
|
-
function
|
16525
|
+
function prependListener(emitter, event2, fn) {
|
16369
16526
|
if (typeof emitter.prependListener === "function") {
|
16370
16527
|
return emitter.prependListener(event2, fn);
|
16371
16528
|
} else {
|
@@ -16719,7 +16876,7 @@ var json2csv_umd = { exports: {} };
|
|
16719
16876
|
if (listenerCount$1(dest, "error") === 0)
|
16720
16877
|
dest.emit("error", er);
|
16721
16878
|
}
|
16722
|
-
|
16879
|
+
prependListener(dest, "error", onerror);
|
16723
16880
|
function onclose() {
|
16724
16881
|
dest.removeListener("finish", onfinish);
|
16725
16882
|
unpipe();
|
@@ -32844,16 +33001,16 @@ function dirname(url) {
|
|
32844
33001
|
return slashIndex >= 0 ? url.substr(0, slashIndex) : "";
|
32845
33002
|
}
|
32846
33003
|
const isBoolean$3 = (x2) => typeof x2 === "boolean";
|
32847
|
-
const isFunction$
|
32848
|
-
const isObject$
|
32849
|
-
const isPureObject = (x2) => isObject$
|
33004
|
+
const isFunction$4 = (x2) => typeof x2 === "function";
|
33005
|
+
const isObject$4 = (x2) => x2 !== null && typeof x2 === "object";
|
33006
|
+
const isPureObject = (x2) => isObject$4(x2) && x2.constructor === {}.constructor;
|
32850
33007
|
const isIterable$1 = (x2) => x2 && typeof x2[Symbol.iterator] === "function";
|
32851
33008
|
const isAsyncIterable$1 = (x2) => x2 && typeof x2[Symbol.asyncIterator] === "function";
|
32852
33009
|
const isResponse = (x2) => typeof Response !== "undefined" && x2 instanceof Response || x2 && x2.arrayBuffer && x2.text && x2.json;
|
32853
33010
|
const isBlob = (x2) => typeof Blob !== "undefined" && x2 instanceof Blob;
|
32854
33011
|
const isBuffer$2 = (x2) => x2 && typeof x2 === "object" && x2.isBuffer;
|
32855
|
-
const isReadableDOMStream = (x2) => typeof ReadableStream !== "undefined" && x2 instanceof ReadableStream || isObject$
|
32856
|
-
const isReadableNodeStream = (x2) => isObject$
|
33012
|
+
const isReadableDOMStream = (x2) => typeof ReadableStream !== "undefined" && x2 instanceof ReadableStream || isObject$4(x2) && isFunction$4(x2.tee) && isFunction$4(x2.cancel) && isFunction$4(x2.getReader);
|
33013
|
+
const isReadableNodeStream = (x2) => isObject$4(x2) && isFunction$4(x2.read) && isFunction$4(x2.pipe) && isBoolean$3(x2.readable);
|
32857
33014
|
const isReadableStream = (x2) => isReadableDOMStream(x2) || isReadableNodeStream(x2);
|
32858
33015
|
const DATA_URL_PATTERN = /^data:([-\w.]+\/[-\w.+]+)(;|,)/;
|
32859
33016
|
const MIME_TYPE_PATTERN = /^([-\w.]+\/[-\w.+]+)/;
|
@@ -33653,7 +33810,7 @@ function getFetchFunction(options, context2) {
|
|
33653
33810
|
if (typeof fetchOptions.fetch === "function") {
|
33654
33811
|
return fetchOptions.fetch;
|
33655
33812
|
}
|
33656
|
-
if (isObject$
|
33813
|
+
if (isObject$4(fetchOptions.fetch)) {
|
33657
33814
|
return (url) => fetchFile(url, fetchOptions);
|
33658
33815
|
}
|
33659
33816
|
if (context2 !== null && context2 !== void 0 && context2.fetch) {
|
@@ -33674,7 +33831,7 @@ function validateOptionsObject(options, id2, defaultOptions2, deprecatedOptions,
|
|
33674
33831
|
const loaderName = id2 || "Top level";
|
33675
33832
|
const prefix2 = id2 ? "".concat(id2, ".") : "";
|
33676
33833
|
for (const key2 in options) {
|
33677
|
-
const isSubOptions = !id2 && isObject$
|
33834
|
+
const isSubOptions = !id2 && isObject$4(options[key2]);
|
33678
33835
|
const isBaseUriOption = key2 === "baseUri" && !id2;
|
33679
33836
|
const isWorkerUrlOption = key2 === "workerUrl" && id2;
|
33680
33837
|
if (!(key2 in defaultOptions2) && !isBaseUriOption && !isWorkerUrlOption) {
|
@@ -52642,9 +52799,9 @@ class Controller {
|
|
52642
52799
|
updateTransition() {
|
52643
52800
|
this.transitionManager.updateTransition();
|
52644
52801
|
}
|
52645
|
-
toggleEvents(
|
52802
|
+
toggleEvents(eventNames, enabled) {
|
52646
52803
|
if (this.eventManager) {
|
52647
|
-
|
52804
|
+
eventNames.forEach((eventName) => {
|
52648
52805
|
if (this._events[eventName] !== enabled) {
|
52649
52806
|
this._events[eventName] = enabled;
|
52650
52807
|
if (enabled) {
|
@@ -56095,18 +56252,18 @@ var hammer$1 = { exports: {} };
|
|
56095
56252
|
emit: function(input) {
|
56096
56253
|
var self2 = this;
|
56097
56254
|
var state = this.state;
|
56098
|
-
function
|
56255
|
+
function emit2(event2) {
|
56099
56256
|
self2.manager.emit(event2, input);
|
56100
56257
|
}
|
56101
56258
|
if (state < STATE_ENDED) {
|
56102
|
-
|
56259
|
+
emit2(self2.options.event + stateStr(state));
|
56103
56260
|
}
|
56104
|
-
|
56261
|
+
emit2(self2.options.event);
|
56105
56262
|
if (input.additionalEvent) {
|
56106
|
-
|
56263
|
+
emit2(input.additionalEvent);
|
56107
56264
|
}
|
56108
56265
|
if (state >= STATE_ENDED) {
|
56109
|
-
|
56266
|
+
emit2(self2.options.event + stateStr(state));
|
56110
56267
|
}
|
56111
56268
|
},
|
56112
56269
|
/**
|
@@ -57466,7 +57623,7 @@ class EventRegistrar {
|
|
57466
57623
|
isEmpty() {
|
57467
57624
|
return !this._active;
|
57468
57625
|
}
|
57469
|
-
add(type2, handler, options,
|
57626
|
+
add(type2, handler, options, once = false, passive = false) {
|
57470
57627
|
const { handlers, handlersByElement } = this;
|
57471
57628
|
let opts2 = DEFAULT_OPTIONS$4;
|
57472
57629
|
if (typeof options === "string" || options && options.addEventListener) {
|
@@ -57485,7 +57642,7 @@ class EventRegistrar {
|
|
57485
57642
|
srcElement: opts2.srcElement,
|
57486
57643
|
priority: opts2.priority
|
57487
57644
|
};
|
57488
|
-
if (
|
57645
|
+
if (once) {
|
57489
57646
|
entry2.once = true;
|
57490
57647
|
}
|
57491
57648
|
if (passive) {
|
@@ -57533,7 +57690,7 @@ class EventRegistrar {
|
|
57533
57690
|
};
|
57534
57691
|
const entriesToRemove = [];
|
57535
57692
|
for (let i2 = 0; i2 < entries2.length; i2++) {
|
57536
|
-
const { type: type2, handler, once
|
57693
|
+
const { type: type2, handler, once } = entries2[i2];
|
57537
57694
|
handler({
|
57538
57695
|
...event2,
|
57539
57696
|
// @ts-ignore
|
@@ -57541,7 +57698,7 @@ class EventRegistrar {
|
|
57541
57698
|
stopPropagation,
|
57542
57699
|
stopImmediatePropagation
|
57543
57700
|
});
|
57544
|
-
if (
|
57701
|
+
if (once) {
|
57545
57702
|
entriesToRemove.push(entries2[i2]);
|
57546
57703
|
}
|
57547
57704
|
if (immediatePropagationStopped) {
|
@@ -57722,11 +57879,11 @@ class EventManager {
|
|
57722
57879
|
/**
|
57723
57880
|
* Process the event registration for a single event + handler.
|
57724
57881
|
*/
|
57725
|
-
_addEventHandler(event2, handler, opts2,
|
57882
|
+
_addEventHandler(event2, handler, opts2, once, passive) {
|
57726
57883
|
if (typeof event2 !== "string") {
|
57727
57884
|
opts2 = handler;
|
57728
57885
|
for (const eventName in event2) {
|
57729
|
-
this._addEventHandler(eventName, event2[eventName], opts2,
|
57886
|
+
this._addEventHandler(eventName, event2[eventName], opts2, once, passive);
|
57730
57887
|
}
|
57731
57888
|
return;
|
57732
57889
|
}
|
@@ -57741,7 +57898,7 @@ class EventManager {
|
|
57741
57898
|
manager.on(eventAlias, eventRegistrar.handleEvent);
|
57742
57899
|
}
|
57743
57900
|
}
|
57744
|
-
eventRegistrar.add(event2, handler, opts2,
|
57901
|
+
eventRegistrar.add(event2, handler, opts2, once, passive);
|
57745
57902
|
if (!eventRegistrar.isEmpty()) {
|
57746
57903
|
this._toggleRecognizer(eventRegistrar.recognizerName, true);
|
57747
57904
|
}
|
@@ -60462,7 +60619,7 @@ function getPropTypes(props) {
|
|
60462
60619
|
const ERR_NOT_OBJECT = "count(): argument not an object";
|
60463
60620
|
const ERR_NOT_CONTAINER = "count(): argument not a container";
|
60464
60621
|
function count$2(container) {
|
60465
|
-
if (!isObject$
|
60622
|
+
if (!isObject$3(container)) {
|
60466
60623
|
throw new Error(ERR_NOT_OBJECT);
|
60467
60624
|
}
|
60468
60625
|
if (typeof container.count === "function") {
|
@@ -60482,7 +60639,7 @@ function count$2(container) {
|
|
60482
60639
|
function isPlainObject(value2) {
|
60483
60640
|
return value2 !== null && typeof value2 === "object" && value2.constructor === Object;
|
60484
60641
|
}
|
60485
|
-
function isObject$
|
60642
|
+
function isObject$3(value2) {
|
60486
60643
|
return value2 !== null && typeof value2 === "object";
|
60487
60644
|
}
|
60488
60645
|
function mergeShaders(target2, source2) {
|
@@ -97118,7 +97275,7 @@ function getCoords$1(coords) {
|
|
97118
97275
|
throw new Error("coords must be GeoJSON Feature, Geometry Object or an Array");
|
97119
97276
|
}
|
97120
97277
|
function containsNumber$1(coordinates2) {
|
97121
|
-
if (coordinates2.length > 1 && isNumber$
|
97278
|
+
if (coordinates2.length > 1 && isNumber$3(coordinates2[0]) && isNumber$3(coordinates2[1])) {
|
97122
97279
|
return true;
|
97123
97280
|
}
|
97124
97281
|
if (Array.isArray(coordinates2[0]) && coordinates2[0].length) {
|
@@ -99317,7 +99474,7 @@ var shams = function hasToStringTagShams() {
|
|
99317
99474
|
};
|
99318
99475
|
var esErrors = Error;
|
99319
99476
|
var _eval = EvalError;
|
99320
|
-
var range$
|
99477
|
+
var range$9 = RangeError;
|
99321
99478
|
var ref$1 = ReferenceError;
|
99322
99479
|
var syntax = SyntaxError;
|
99323
99480
|
var type$1 = TypeError;
|
@@ -99425,7 +99582,7 @@ var hasown = bind$3.call(call, $hasOwn);
|
|
99425
99582
|
var undefined$2;
|
99426
99583
|
var $Error = esErrors;
|
99427
99584
|
var $EvalError = _eval;
|
99428
|
-
var $RangeError = range$
|
99585
|
+
var $RangeError = range$9;
|
99429
99586
|
var $ReferenceError = ref$1;
|
99430
99587
|
var $SyntaxError$1 = syntax;
|
99431
99588
|
var $TypeError$4 = type$1;
|
@@ -99941,7 +100098,7 @@ var hasSymbols2 = typeof Symbol === "function" && typeof Symbol("foo") === "symb
|
|
99941
100098
|
var toStr$1 = Object.prototype.toString;
|
99942
100099
|
var concat = Array.prototype.concat;
|
99943
100100
|
var defineDataProperty2 = defineDataProperty$1;
|
99944
|
-
var isFunction$
|
100101
|
+
var isFunction$3 = function(fn) {
|
99945
100102
|
return typeof fn === "function" && toStr$1.call(fn) === "[object Function]";
|
99946
100103
|
};
|
99947
100104
|
var supportsDescriptors$2 = hasPropertyDescriptors_1();
|
@@ -99951,7 +100108,7 @@ var defineProperty$1 = function(object2, name2, value2, predicate) {
|
|
99951
100108
|
if (object2[name2] === value2) {
|
99952
100109
|
return;
|
99953
100110
|
}
|
99954
|
-
} else if (!isFunction$
|
100111
|
+
} else if (!isFunction$3(predicate) || !predicate()) {
|
99955
100112
|
return;
|
99956
100113
|
}
|
99957
100114
|
}
|
@@ -100335,7 +100492,7 @@ function lineOverlap(line1, line2, options) {
|
|
100335
100492
|
options = {};
|
100336
100493
|
}
|
100337
100494
|
options = options || {};
|
100338
|
-
if (!isObject$
|
100495
|
+
if (!isObject$5(options))
|
100339
100496
|
throw new Error("options is invalid");
|
100340
100497
|
var tolerance = options.tolerance || 0;
|
100341
100498
|
var features = [];
|
@@ -100895,19 +101052,19 @@ var jsts_min = { exports: {} };
|
|
100895
101052
|
}, Object.defineProperties(w2, O);
|
100896
101053
|
var T = function(t5, e4) {
|
100897
101054
|
return t5.interfaces_ && t5.interfaces_().indexOf(e4) > -1;
|
100898
|
-
},
|
101055
|
+
}, R = function() {
|
100899
101056
|
}, P = { LOG_10: { configurable: true } };
|
100900
|
-
|
101057
|
+
R.prototype.interfaces_ = function() {
|
100901
101058
|
return [];
|
100902
|
-
},
|
100903
|
-
return
|
100904
|
-
},
|
101059
|
+
}, R.prototype.getClass = function() {
|
101060
|
+
return R;
|
101061
|
+
}, R.log10 = function(t5) {
|
100905
101062
|
var e4 = Math.log(t5);
|
100906
|
-
return v.isInfinite(e4) ? e4 : v.isNaN(e4) ? e4 : e4 /
|
100907
|
-
},
|
101063
|
+
return v.isInfinite(e4) ? e4 : v.isNaN(e4) ? e4 : e4 / R.LOG_10;
|
101064
|
+
}, R.min = function(t5, e4, n3, i3) {
|
100908
101065
|
var r4 = t5;
|
100909
101066
|
return e4 < r4 && (r4 = e4), n3 < r4 && (r4 = n3), i3 < r4 && (r4 = i3), r4;
|
100910
|
-
},
|
101067
|
+
}, R.clamp = function() {
|
100911
101068
|
if ("number" == typeof arguments[2] && "number" == typeof arguments[0] && "number" == typeof arguments[1]) {
|
100912
101069
|
var t5 = arguments[0], e4 = arguments[1], n3 = arguments[2];
|
100913
101070
|
return t5 < e4 ? e4 : t5 > n3 ? n3 : t5;
|
@@ -100916,9 +101073,9 @@ var jsts_min = { exports: {} };
|
|
100916
101073
|
var i3 = arguments[0], r4 = arguments[1], o3 = arguments[2];
|
100917
101074
|
return i3 < r4 ? r4 : i3 > o3 ? o3 : i3;
|
100918
101075
|
}
|
100919
|
-
},
|
101076
|
+
}, R.wrap = function(t5, e4) {
|
100920
101077
|
return t5 < 0 ? e4 - -t5 % e4 : t5 % e4;
|
100921
|
-
},
|
101078
|
+
}, R.max = function() {
|
100922
101079
|
if (3 === arguments.length) {
|
100923
101080
|
var t5 = arguments[0], e4 = arguments[1], n3 = arguments[2], i3 = t5;
|
100924
101081
|
return e4 > i3 && (i3 = e4), n3 > i3 && (i3 = n3), i3;
|
@@ -100927,11 +101084,11 @@ var jsts_min = { exports: {} };
|
|
100927
101084
|
var r4 = arguments[0], o3 = arguments[1], s3 = arguments[2], a3 = arguments[3], u3 = r4;
|
100928
101085
|
return o3 > u3 && (u3 = o3), s3 > u3 && (u3 = s3), a3 > u3 && (u3 = a3), u3;
|
100929
101086
|
}
|
100930
|
-
},
|
101087
|
+
}, R.average = function(t5, e4) {
|
100931
101088
|
return (t5 + e4) / 2;
|
100932
101089
|
}, P.LOG_10.get = function() {
|
100933
101090
|
return Math.log(10);
|
100934
|
-
}, Object.defineProperties(
|
101091
|
+
}, Object.defineProperties(R, P);
|
100935
101092
|
var D2 = function(t5) {
|
100936
101093
|
this.str = t5;
|
100937
101094
|
};
|
@@ -102086,7 +102243,7 @@ var jsts_min = { exports: {} };
|
|
102086
102243
|
}
|
102087
102244
|
} else
|
102088
102245
|
r4 = true;
|
102089
|
-
return r4 ?
|
102246
|
+
return r4 ? R.min(at2.distancePointLine(t5, n3, i3), at2.distancePointLine(e4, n3, i3), at2.distancePointLine(n3, t5, e4), at2.distancePointLine(i3, t5, e4)) : 0;
|
102090
102247
|
}, at2.isPointInRing = function(t5, e4) {
|
102091
102248
|
return at2.locatePointInRing(t5, e4) !== w2.EXTERIOR;
|
102092
102249
|
}, at2.computeLength = function(t5) {
|
@@ -102676,8 +102833,8 @@ var jsts_min = { exports: {} };
|
|
102676
102833
|
(null === e4 || e4.compareTo(t5[n3]) > 0) && (e4 = t5[n3]);
|
102677
102834
|
return e4;
|
102678
102835
|
}, Lt.extract = function(t5, e4, n3) {
|
102679
|
-
e4 =
|
102680
|
-
var i3 = (n3 =
|
102836
|
+
e4 = R.clamp(e4, 0, t5.length);
|
102837
|
+
var i3 = (n3 = R.clamp(n3, -1, t5.length)) - e4 + 1;
|
102681
102838
|
n3 < 0 && (i3 = 0), e4 >= t5.length && (i3 = 0), n3 < e4 && (i3 = 0);
|
102682
102839
|
var r4 = new Array(i3).fill(null);
|
102683
102840
|
if (0 === i3)
|
@@ -108422,7 +108579,7 @@ var jsts_min = { exports: {} };
|
|
108422
108579
|
return f3.getResultGeometry(c3);
|
108423
108580
|
}
|
108424
108581
|
}, di.precisionScaleFactor = function(t5, e4, n3) {
|
108425
|
-
var i3 = t5.getEnvelopeInternal(), r4 =
|
108582
|
+
var i3 = t5.getEnvelopeInternal(), r4 = R.max(Math.abs(i3.getMaxX()), Math.abs(i3.getMaxY()), Math.abs(i3.getMinX()), Math.abs(i3.getMinY())) + 2 * (e4 > 0 ? e4 : 0), o3 = n3 - Math.trunc(Math.log(r4) / Math.log(10) + 1);
|
108426
108583
|
return Math.pow(10, o3);
|
108427
108584
|
}, yi.CAP_ROUND.get = function() {
|
108428
108585
|
return Cn.CAP_ROUND;
|
@@ -110940,7 +111097,7 @@ function cartesianNormalizeInPlace$1(d) {
|
|
110940
111097
|
var l2 = sqrt$5(d[0] * d[0] + d[1] * d[1] + d[2] * d[2]);
|
110941
111098
|
d[0] /= l2, d[1] /= l2, d[2] /= l2;
|
110942
111099
|
}
|
110943
|
-
var lambda0$3, phi0$1, lambda1$1, phi1$1, lambda2$1, lambda00$4, phi00$4, p0$1, deltaSum$1 = adder(), ranges$1, range$
|
111100
|
+
var lambda0$3, phi0$1, lambda1$1, phi1$1, lambda2$1, lambda00$4, phi00$4, p0$1, deltaSum$1 = adder(), ranges$1, range$8;
|
110944
111101
|
var boundsStream$4 = {
|
110945
111102
|
point: boundsPoint$3,
|
110946
111103
|
lineStart: boundsLineStart$1,
|
@@ -110963,11 +111120,11 @@ var boundsStream$4 = {
|
|
110963
111120
|
phi1$1 = 90;
|
110964
111121
|
else if (deltaSum$1 < -epsilon$8)
|
110965
111122
|
phi0$1 = -90;
|
110966
|
-
range$
|
111123
|
+
range$8[0] = lambda0$3, range$8[1] = lambda1$1;
|
110967
111124
|
}
|
110968
111125
|
};
|
110969
111126
|
function boundsPoint$3(lambda, phi2) {
|
110970
|
-
ranges$1.push(range$
|
111127
|
+
ranges$1.push(range$8 = [lambda0$3 = lambda, lambda1$1 = lambda]);
|
110971
111128
|
if (phi2 < phi0$1)
|
110972
111129
|
phi0$1 = phi2;
|
110973
111130
|
if (phi2 > phi1$1)
|
@@ -111019,7 +111176,7 @@ function linePoint$1(lambda, phi2) {
|
|
111019
111176
|
}
|
111020
111177
|
}
|
111021
111178
|
} else {
|
111022
|
-
ranges$1.push(range$
|
111179
|
+
ranges$1.push(range$8 = [lambda0$3 = lambda, lambda1$1 = lambda]);
|
111023
111180
|
}
|
111024
111181
|
if (phi2 < phi0$1)
|
111025
111182
|
phi0$1 = phi2;
|
@@ -111031,7 +111188,7 @@ function boundsLineStart$1() {
|
|
111031
111188
|
boundsStream$4.point = linePoint$1;
|
111032
111189
|
}
|
111033
111190
|
function boundsLineEnd$1() {
|
111034
|
-
range$
|
111191
|
+
range$8[0] = lambda0$3, range$8[1] = lambda1$1;
|
111035
111192
|
boundsStream$4.point = boundsPoint$3;
|
111036
111193
|
p0$1 = null;
|
111037
111194
|
}
|
@@ -111053,7 +111210,7 @@ function boundsRingEnd$1() {
|
|
111053
111210
|
areaStream$3.lineEnd();
|
111054
111211
|
if (abs$3(deltaSum$1) > epsilon$8)
|
111055
111212
|
lambda0$3 = -(lambda1$1 = 180);
|
111056
|
-
range$
|
111213
|
+
range$8[0] = lambda0$3, range$8[1] = lambda1$1;
|
111057
111214
|
p0$1 = null;
|
111058
111215
|
}
|
111059
111216
|
function angle$1(lambda02, lambda12) {
|
@@ -111089,7 +111246,7 @@ function bounds$1(feature2) {
|
|
111089
111246
|
deltaMax = delta, lambda0$3 = b2[0], lambda1$1 = a2[1];
|
111090
111247
|
}
|
111091
111248
|
}
|
111092
|
-
ranges$1 = range$
|
111249
|
+
ranges$1 = range$8 = null;
|
111093
111250
|
return lambda0$3 === Infinity || phi0$1 === Infinity ? [[NaN, NaN], [NaN, NaN]] : [[lambda0$3, phi0$1], [lambda1$1, phi1$1]];
|
111094
111251
|
}
|
111095
111252
|
var W0$1, W1$1, X0$3, Y0$3, Z0$3, X1$3, Y1$3, Z1$3, X2$4, Y2$4, Z2$3, lambda00$3, phi00$3, x0$9, y0$9, z0$1;
|
@@ -111514,7 +111671,7 @@ function ascendingComparator$1(f2) {
|
|
111514
111671
|
};
|
111515
111672
|
}
|
111516
111673
|
bisector$3(ascending$6);
|
111517
|
-
function range$
|
111674
|
+
function range$7(start, stop3, step) {
|
111518
111675
|
start = +start, stop3 = +stop3, step = (n2 = arguments.length) < 2 ? (stop3 = start, start = 0, 1) : n2 < 3 ? 1 : +step;
|
111519
111676
|
var i2 = -1, n2 = Math.max(0, Math.ceil((stop3 - start) / step)) | 0, range2 = new Array(n2);
|
111520
111677
|
while (++i2 < n2) {
|
@@ -111665,7 +111822,7 @@ function clipExtent(x02, y02, x12, y12) {
|
|
111665
111822
|
return clipStream;
|
111666
111823
|
};
|
111667
111824
|
}
|
111668
|
-
function extent$
|
111825
|
+
function extent$1() {
|
111669
111826
|
var x02 = 0, y02 = 0, x12 = 960, y12 = 500, cache2, cacheStream, clip2;
|
111670
111827
|
return clip2 = {
|
111671
111828
|
stream: function(stream2) {
|
@@ -111817,7 +111974,7 @@ function contains$2(object2, point2) {
|
|
111817
111974
|
return (object2 && containsObjectType.hasOwnProperty(object2.type) ? containsObjectType[object2.type] : containsGeometry)(object2, point2);
|
111818
111975
|
}
|
111819
111976
|
function graticuleX$1(y02, y12, dy) {
|
111820
|
-
var y2 = range$
|
111977
|
+
var y2 = range$7(y02, y12 - epsilon$8, dy).concat(y12);
|
111821
111978
|
return function(x2) {
|
111822
111979
|
return y2.map(function(y22) {
|
111823
111980
|
return [x2, y22];
|
@@ -111825,7 +111982,7 @@ function graticuleX$1(y02, y12, dy) {
|
|
111825
111982
|
};
|
111826
111983
|
}
|
111827
111984
|
function graticuleY$1(x02, x12, dx) {
|
111828
|
-
var x2 = range$
|
111985
|
+
var x2 = range$7(x02, x12 - epsilon$8, dx).concat(x12);
|
111829
111986
|
return function(y2) {
|
111830
111987
|
return x2.map(function(x22) {
|
111831
111988
|
return [x22, y2];
|
@@ -111838,9 +111995,9 @@ function graticule$1() {
|
|
111838
111995
|
return { type: "MultiLineString", coordinates: lines() };
|
111839
111996
|
}
|
111840
111997
|
function lines() {
|
111841
|
-
return range$
|
111998
|
+
return range$7(ceil$1(X02 / DX) * DX, X12, DX).map(X3).concat(range$7(ceil$1(Y02 / DY) * DY, Y12, DY).map(Y3)).concat(range$7(ceil$1(x02 / dx) * dx, x12, dx).filter(function(x22) {
|
111842
111999
|
return abs$3(x22 % DX) > epsilon$8;
|
111843
|
-
}).map(x2)).concat(range$
|
112000
|
+
}).map(x2)).concat(range$7(ceil$1(y02 / dy) * dy, y12, dy).filter(function(y22) {
|
111844
112001
|
return abs$3(y22 % DY) > epsilon$8;
|
111845
112002
|
}).map(y2));
|
111846
112003
|
}
|
@@ -113072,7 +113229,7 @@ const d3Geo$1 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.definePrope
|
|
113072
113229
|
geoBounds: bounds$1,
|
113073
113230
|
geoCentroid: centroid$3,
|
113074
113231
|
geoCircle: circle$5,
|
113075
|
-
geoClipExtent: extent$
|
113232
|
+
geoClipExtent: extent$1,
|
113076
113233
|
geoConicConformal: conicConformal,
|
113077
113234
|
geoConicConformalRaw: conicConformalRaw$1,
|
113078
113235
|
geoConicEqualArea: conicEqualArea,
|
@@ -115813,372 +115970,216 @@ var layerMouseEvent = {};
|
|
115813
115970
|
exports2["default"] = LayerMouseEvent;
|
115814
115971
|
})(layerMouseEvent);
|
115815
115972
|
var nebulaLayer = {};
|
115816
|
-
var events$3 = { exports: {} };
|
115817
|
-
var R = typeof Reflect === "object" ? Reflect : null;
|
115818
|
-
var ReflectApply = R && typeof R.apply === "function" ? R.apply : function ReflectApply2(target2, receiver, args) {
|
115819
|
-
return Function.prototype.apply.call(target2, receiver, args);
|
115820
|
-
};
|
115821
|
-
var ReflectOwnKeys;
|
115822
|
-
if (R && typeof R.ownKeys === "function") {
|
115823
|
-
ReflectOwnKeys = R.ownKeys;
|
115824
|
-
} else if (Object.getOwnPropertySymbols) {
|
115825
|
-
ReflectOwnKeys = function ReflectOwnKeys2(target2) {
|
115826
|
-
return Object.getOwnPropertyNames(target2).concat(Object.getOwnPropertySymbols(target2));
|
115827
|
-
};
|
115828
|
-
} else {
|
115829
|
-
ReflectOwnKeys = function ReflectOwnKeys2(target2) {
|
115830
|
-
return Object.getOwnPropertyNames(target2);
|
115831
|
-
};
|
115832
|
-
}
|
115833
|
-
function ProcessEmitWarning(warning2) {
|
115834
|
-
if (console && console.warn)
|
115835
|
-
console.warn(warning2);
|
115836
|
-
}
|
115837
|
-
var NumberIsNaN = Number.isNaN || function NumberIsNaN2(value2) {
|
115838
|
-
return value2 !== value2;
|
115839
|
-
};
|
115840
115973
|
function EventEmitter() {
|
115841
|
-
|
115974
|
+
this._events = this._events || {};
|
115975
|
+
this._maxListeners = this._maxListeners || void 0;
|
115842
115976
|
}
|
115843
|
-
events$3
|
115844
|
-
events$3.exports.once = once2;
|
115977
|
+
var events$3 = EventEmitter;
|
115845
115978
|
EventEmitter.EventEmitter = EventEmitter;
|
115846
115979
|
EventEmitter.prototype._events = void 0;
|
115847
|
-
EventEmitter.prototype._eventsCount = 0;
|
115848
115980
|
EventEmitter.prototype._maxListeners = void 0;
|
115849
|
-
|
115850
|
-
function
|
115851
|
-
if (
|
115852
|
-
throw
|
115853
|
-
}
|
115854
|
-
}
|
115855
|
-
Object.defineProperty(EventEmitter, "defaultMaxListeners", {
|
115856
|
-
enumerable: true,
|
115857
|
-
get: function() {
|
115858
|
-
return defaultMaxListeners;
|
115859
|
-
},
|
115860
|
-
set: function(arg) {
|
115861
|
-
if (typeof arg !== "number" || arg < 0 || NumberIsNaN(arg)) {
|
115862
|
-
throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received ' + arg + ".");
|
115863
|
-
}
|
115864
|
-
defaultMaxListeners = arg;
|
115865
|
-
}
|
115866
|
-
});
|
115867
|
-
EventEmitter.init = function() {
|
115868
|
-
if (this._events === void 0 || this._events === Object.getPrototypeOf(this)._events) {
|
115869
|
-
this._events = /* @__PURE__ */ Object.create(null);
|
115870
|
-
this._eventsCount = 0;
|
115871
|
-
}
|
115872
|
-
this._maxListeners = this._maxListeners || void 0;
|
115873
|
-
};
|
115874
|
-
EventEmitter.prototype.setMaxListeners = function setMaxListeners(n2) {
|
115875
|
-
if (typeof n2 !== "number" || n2 < 0 || NumberIsNaN(n2)) {
|
115876
|
-
throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received ' + n2 + ".");
|
115877
|
-
}
|
115981
|
+
EventEmitter.defaultMaxListeners = 10;
|
115982
|
+
EventEmitter.prototype.setMaxListeners = function(n2) {
|
115983
|
+
if (!isNumber$2(n2) || n2 < 0 || isNaN(n2))
|
115984
|
+
throw TypeError("n must be a positive number");
|
115878
115985
|
this._maxListeners = n2;
|
115879
115986
|
return this;
|
115880
115987
|
};
|
115881
|
-
function
|
115882
|
-
|
115883
|
-
|
115884
|
-
|
115885
|
-
|
115886
|
-
|
115887
|
-
|
115888
|
-
|
115889
|
-
|
115890
|
-
|
115891
|
-
|
115892
|
-
|
115893
|
-
|
115894
|
-
|
115895
|
-
|
115896
|
-
|
115897
|
-
|
115898
|
-
|
115899
|
-
if (doError) {
|
115900
|
-
var er;
|
115901
|
-
if (args.length > 0)
|
115902
|
-
er = args[0];
|
115903
|
-
if (er instanceof Error) {
|
115904
|
-
throw er;
|
115905
|
-
}
|
115906
|
-
var err2 = new Error("Unhandled error." + (er ? " (" + er.message + ")" : ""));
|
115907
|
-
err2.context = er;
|
115908
|
-
throw err2;
|
115909
|
-
}
|
115910
|
-
var handler = events2[type2];
|
115911
|
-
if (handler === void 0)
|
115988
|
+
EventEmitter.prototype.emit = function(type2) {
|
115989
|
+
var er, handler, len2, args, i2, listeners;
|
115990
|
+
if (!this._events)
|
115991
|
+
this._events = {};
|
115992
|
+
if (type2 === "error") {
|
115993
|
+
if (!this._events.error || isObject$2(this._events.error) && !this._events.error.length) {
|
115994
|
+
er = arguments[1];
|
115995
|
+
if (er instanceof Error) {
|
115996
|
+
throw er;
|
115997
|
+
} else {
|
115998
|
+
var err2 = new Error('Uncaught, unspecified "error" event. (' + er + ")");
|
115999
|
+
err2.context = er;
|
116000
|
+
throw err2;
|
116001
|
+
}
|
116002
|
+
}
|
116003
|
+
}
|
116004
|
+
handler = this._events[type2];
|
116005
|
+
if (isUndefined(handler))
|
115912
116006
|
return false;
|
115913
|
-
if (
|
115914
|
-
|
115915
|
-
|
115916
|
-
|
115917
|
-
|
115918
|
-
|
115919
|
-
|
116007
|
+
if (isFunction$2(handler)) {
|
116008
|
+
switch (arguments.length) {
|
116009
|
+
case 1:
|
116010
|
+
handler.call(this);
|
116011
|
+
break;
|
116012
|
+
case 2:
|
116013
|
+
handler.call(this, arguments[1]);
|
116014
|
+
break;
|
116015
|
+
case 3:
|
116016
|
+
handler.call(this, arguments[1], arguments[2]);
|
116017
|
+
break;
|
116018
|
+
default:
|
116019
|
+
args = Array.prototype.slice.call(arguments, 1);
|
116020
|
+
handler.apply(this, args);
|
116021
|
+
}
|
116022
|
+
} else if (isObject$2(handler)) {
|
116023
|
+
args = Array.prototype.slice.call(arguments, 1);
|
116024
|
+
listeners = handler.slice();
|
116025
|
+
len2 = listeners.length;
|
116026
|
+
for (i2 = 0; i2 < len2; i2++)
|
116027
|
+
listeners[i2].apply(this, args);
|
115920
116028
|
}
|
115921
116029
|
return true;
|
115922
116030
|
};
|
115923
|
-
function
|
116031
|
+
EventEmitter.prototype.addListener = function(type2, listener2) {
|
115924
116032
|
var m2;
|
115925
|
-
|
115926
|
-
|
115927
|
-
|
115928
|
-
|
115929
|
-
if (
|
115930
|
-
|
115931
|
-
|
115932
|
-
|
115933
|
-
|
115934
|
-
|
115935
|
-
|
115936
|
-
|
115937
|
-
|
115938
|
-
|
115939
|
-
|
115940
|
-
|
115941
|
-
|
115942
|
-
|
115943
|
-
|
115944
|
-
existing = events2[type2] = listener2;
|
115945
|
-
++target2._eventsCount;
|
115946
|
-
} else {
|
115947
|
-
if (typeof existing === "function") {
|
115948
|
-
existing = events2[type2] = prepend ? [listener2, existing] : [existing, listener2];
|
115949
|
-
} else if (prepend) {
|
115950
|
-
existing.unshift(listener2);
|
116033
|
+
if (!isFunction$2(listener2))
|
116034
|
+
throw TypeError("listener must be a function");
|
116035
|
+
if (!this._events)
|
116036
|
+
this._events = {};
|
116037
|
+
if (this._events.newListener)
|
116038
|
+
this.emit(
|
116039
|
+
"newListener",
|
116040
|
+
type2,
|
116041
|
+
isFunction$2(listener2.listener) ? listener2.listener : listener2
|
116042
|
+
);
|
116043
|
+
if (!this._events[type2])
|
116044
|
+
this._events[type2] = listener2;
|
116045
|
+
else if (isObject$2(this._events[type2]))
|
116046
|
+
this._events[type2].push(listener2);
|
116047
|
+
else
|
116048
|
+
this._events[type2] = [this._events[type2], listener2];
|
116049
|
+
if (isObject$2(this._events[type2]) && !this._events[type2].warned) {
|
116050
|
+
if (!isUndefined(this._maxListeners)) {
|
116051
|
+
m2 = this._maxListeners;
|
115951
116052
|
} else {
|
115952
|
-
|
116053
|
+
m2 = EventEmitter.defaultMaxListeners;
|
115953
116054
|
}
|
115954
|
-
m2
|
115955
|
-
|
115956
|
-
|
115957
|
-
|
115958
|
-
|
115959
|
-
|
115960
|
-
|
115961
|
-
|
115962
|
-
|
116055
|
+
if (m2 && m2 > 0 && this._events[type2].length > m2) {
|
116056
|
+
this._events[type2].warned = true;
|
116057
|
+
console.error(
|
116058
|
+
"(node) warning: possible EventEmitter memory leak detected. %d listeners added. Use emitter.setMaxListeners() to increase limit.",
|
116059
|
+
this._events[type2].length
|
116060
|
+
);
|
116061
|
+
if (typeof console.trace === "function") {
|
116062
|
+
console.trace();
|
116063
|
+
}
|
115963
116064
|
}
|
115964
116065
|
}
|
115965
|
-
return target2;
|
115966
|
-
}
|
115967
|
-
EventEmitter.prototype.addListener = function addListener(type2, listener2) {
|
115968
|
-
return _addListener(this, type2, listener2, false);
|
115969
|
-
};
|
115970
|
-
EventEmitter.prototype.on = EventEmitter.prototype.addListener;
|
115971
|
-
EventEmitter.prototype.prependListener = function prependListener(type2, listener2) {
|
115972
|
-
return _addListener(this, type2, listener2, true);
|
115973
|
-
};
|
115974
|
-
function onceWrapper() {
|
115975
|
-
if (!this.fired) {
|
115976
|
-
this.target.removeListener(this.type, this.wrapFn);
|
115977
|
-
this.fired = true;
|
115978
|
-
if (arguments.length === 0)
|
115979
|
-
return this.listener.call(this.target);
|
115980
|
-
return this.listener.apply(this.target, arguments);
|
115981
|
-
}
|
115982
|
-
}
|
115983
|
-
function _onceWrap(target2, type2, listener2) {
|
115984
|
-
var state = { fired: false, wrapFn: void 0, target: target2, type: type2, listener: listener2 };
|
115985
|
-
var wrapped = onceWrapper.bind(state);
|
115986
|
-
wrapped.listener = listener2;
|
115987
|
-
state.wrapFn = wrapped;
|
115988
|
-
return wrapped;
|
115989
|
-
}
|
115990
|
-
EventEmitter.prototype.once = function once(type2, listener2) {
|
115991
|
-
checkListener(listener2);
|
115992
|
-
this.on(type2, _onceWrap(this, type2, listener2));
|
115993
116066
|
return this;
|
115994
116067
|
};
|
115995
|
-
EventEmitter.prototype.
|
115996
|
-
|
115997
|
-
|
116068
|
+
EventEmitter.prototype.on = EventEmitter.prototype.addListener;
|
116069
|
+
EventEmitter.prototype.once = function(type2, listener2) {
|
116070
|
+
if (!isFunction$2(listener2))
|
116071
|
+
throw TypeError("listener must be a function");
|
116072
|
+
var fired = false;
|
116073
|
+
function g2() {
|
116074
|
+
this.removeListener(type2, g2);
|
116075
|
+
if (!fired) {
|
116076
|
+
fired = true;
|
116077
|
+
listener2.apply(this, arguments);
|
116078
|
+
}
|
116079
|
+
}
|
116080
|
+
g2.listener = listener2;
|
116081
|
+
this.on(type2, g2);
|
115998
116082
|
return this;
|
115999
116083
|
};
|
116000
|
-
EventEmitter.prototype.removeListener = function
|
116001
|
-
var list,
|
116002
|
-
|
116003
|
-
|
116004
|
-
if (
|
116005
|
-
return this;
|
116006
|
-
list = events2[type2];
|
116007
|
-
if (list === void 0)
|
116084
|
+
EventEmitter.prototype.removeListener = function(type2, listener2) {
|
116085
|
+
var list, position2, length2, i2;
|
116086
|
+
if (!isFunction$2(listener2))
|
116087
|
+
throw TypeError("listener must be a function");
|
116088
|
+
if (!this._events || !this._events[type2])
|
116008
116089
|
return this;
|
116009
|
-
|
116010
|
-
|
116011
|
-
|
116012
|
-
|
116013
|
-
|
116014
|
-
|
116015
|
-
|
116016
|
-
|
116017
|
-
|
116018
|
-
|
116019
|
-
for (i2 = list.length - 1; i2 >= 0; i2--) {
|
116020
|
-
if (list[i2] === listener2 || list[i2].listener === listener2) {
|
116021
|
-
originalListener = list[i2].listener;
|
116090
|
+
list = this._events[type2];
|
116091
|
+
length2 = list.length;
|
116092
|
+
position2 = -1;
|
116093
|
+
if (list === listener2 || isFunction$2(list.listener) && list.listener === listener2) {
|
116094
|
+
delete this._events[type2];
|
116095
|
+
if (this._events.removeListener)
|
116096
|
+
this.emit("removeListener", type2, listener2);
|
116097
|
+
} else if (isObject$2(list)) {
|
116098
|
+
for (i2 = length2; i2-- > 0; ) {
|
116099
|
+
if (list[i2] === listener2 || list[i2].listener && list[i2].listener === listener2) {
|
116022
116100
|
position2 = i2;
|
116023
116101
|
break;
|
116024
116102
|
}
|
116025
116103
|
}
|
116026
116104
|
if (position2 < 0)
|
116027
116105
|
return this;
|
116028
|
-
if (
|
116029
|
-
list.
|
116030
|
-
|
116031
|
-
|
116106
|
+
if (list.length === 1) {
|
116107
|
+
list.length = 0;
|
116108
|
+
delete this._events[type2];
|
116109
|
+
} else {
|
116110
|
+
list.splice(position2, 1);
|
116032
116111
|
}
|
116033
|
-
if (
|
116034
|
-
|
116035
|
-
if (events2.removeListener !== void 0)
|
116036
|
-
this.emit("removeListener", type2, originalListener || listener2);
|
116112
|
+
if (this._events.removeListener)
|
116113
|
+
this.emit("removeListener", type2, listener2);
|
116037
116114
|
}
|
116038
116115
|
return this;
|
116039
116116
|
};
|
116040
|
-
EventEmitter.prototype.
|
116041
|
-
|
116042
|
-
|
116043
|
-
events2 = this._events;
|
116044
|
-
if (events2 === void 0)
|
116117
|
+
EventEmitter.prototype.removeAllListeners = function(type2) {
|
116118
|
+
var key2, listeners;
|
116119
|
+
if (!this._events)
|
116045
116120
|
return this;
|
116046
|
-
if (
|
116047
|
-
if (arguments.length === 0)
|
116048
|
-
this._events =
|
116049
|
-
|
116050
|
-
|
116051
|
-
if (--this._eventsCount === 0)
|
116052
|
-
this._events = /* @__PURE__ */ Object.create(null);
|
116053
|
-
else
|
116054
|
-
delete events2[type2];
|
116055
|
-
}
|
116121
|
+
if (!this._events.removeListener) {
|
116122
|
+
if (arguments.length === 0)
|
116123
|
+
this._events = {};
|
116124
|
+
else if (this._events[type2])
|
116125
|
+
delete this._events[type2];
|
116056
116126
|
return this;
|
116057
116127
|
}
|
116058
116128
|
if (arguments.length === 0) {
|
116059
|
-
|
116060
|
-
var key2;
|
116061
|
-
for (i2 = 0; i2 < keys3.length; ++i2) {
|
116062
|
-
key2 = keys3[i2];
|
116129
|
+
for (key2 in this._events) {
|
116063
116130
|
if (key2 === "removeListener")
|
116064
116131
|
continue;
|
116065
116132
|
this.removeAllListeners(key2);
|
116066
116133
|
}
|
116067
116134
|
this.removeAllListeners("removeListener");
|
116068
|
-
this._events =
|
116069
|
-
this._eventsCount = 0;
|
116135
|
+
this._events = {};
|
116070
116136
|
return this;
|
116071
116137
|
}
|
116072
|
-
|
116073
|
-
if (
|
116074
|
-
this.removeListener(type2,
|
116075
|
-
} else if (
|
116076
|
-
|
116077
|
-
this.removeListener(type2,
|
116078
|
-
}
|
116138
|
+
listeners = this._events[type2];
|
116139
|
+
if (isFunction$2(listeners)) {
|
116140
|
+
this.removeListener(type2, listeners);
|
116141
|
+
} else if (listeners) {
|
116142
|
+
while (listeners.length)
|
116143
|
+
this.removeListener(type2, listeners[listeners.length - 1]);
|
116079
116144
|
}
|
116145
|
+
delete this._events[type2];
|
116080
116146
|
return this;
|
116081
116147
|
};
|
116082
|
-
function
|
116083
|
-
var
|
116084
|
-
if (
|
116085
|
-
|
116086
|
-
|
116087
|
-
|
116088
|
-
|
116089
|
-
|
116090
|
-
|
116091
|
-
return unwrap ? unwrapListeners(evlistener) : arrayClone(evlistener, evlistener.length);
|
116092
|
-
}
|
116093
|
-
EventEmitter.prototype.listeners = function listeners(type2) {
|
116094
|
-
return _listeners(this, type2, true);
|
116095
|
-
};
|
116096
|
-
EventEmitter.prototype.rawListeners = function rawListeners(type2) {
|
116097
|
-
return _listeners(this, type2, false);
|
116098
|
-
};
|
116099
|
-
EventEmitter.listenerCount = function(emitter, type2) {
|
116100
|
-
if (typeof emitter.listenerCount === "function") {
|
116101
|
-
return emitter.listenerCount(type2);
|
116102
|
-
} else {
|
116103
|
-
return listenerCount.call(emitter, type2);
|
116104
|
-
}
|
116148
|
+
EventEmitter.prototype.listeners = function(type2) {
|
116149
|
+
var ret;
|
116150
|
+
if (!this._events || !this._events[type2])
|
116151
|
+
ret = [];
|
116152
|
+
else if (isFunction$2(this._events[type2]))
|
116153
|
+
ret = [this._events[type2]];
|
116154
|
+
else
|
116155
|
+
ret = this._events[type2].slice();
|
116156
|
+
return ret;
|
116105
116157
|
};
|
116106
|
-
EventEmitter.prototype.listenerCount =
|
116107
|
-
|
116108
|
-
|
116109
|
-
|
116110
|
-
var evlistener = events2[type2];
|
116111
|
-
if (typeof evlistener === "function") {
|
116158
|
+
EventEmitter.prototype.listenerCount = function(type2) {
|
116159
|
+
if (this._events) {
|
116160
|
+
var evlistener = this._events[type2];
|
116161
|
+
if (isFunction$2(evlistener))
|
116112
116162
|
return 1;
|
116113
|
-
|
116163
|
+
else if (evlistener)
|
116114
116164
|
return evlistener.length;
|
116115
|
-
}
|
116116
116165
|
}
|
116117
116166
|
return 0;
|
116118
|
-
}
|
116119
|
-
EventEmitter.prototype.eventNames = function eventNames() {
|
116120
|
-
return this._eventsCount > 0 ? ReflectOwnKeys(this._events) : [];
|
116121
116167
|
};
|
116122
|
-
function
|
116123
|
-
|
116124
|
-
|
116125
|
-
|
116126
|
-
return
|
116127
|
-
}
|
116128
|
-
function spliceOne(list, index2) {
|
116129
|
-
for (; index2 + 1 < list.length; index2++)
|
116130
|
-
list[index2] = list[index2 + 1];
|
116131
|
-
list.pop();
|
116132
|
-
}
|
116133
|
-
function unwrapListeners(arr) {
|
116134
|
-
var ret = new Array(arr.length);
|
116135
|
-
for (var i2 = 0; i2 < ret.length; ++i2) {
|
116136
|
-
ret[i2] = arr[i2].listener || arr[i2];
|
116137
|
-
}
|
116138
|
-
return ret;
|
116168
|
+
EventEmitter.listenerCount = function(emitter, type2) {
|
116169
|
+
return emitter.listenerCount(type2);
|
116170
|
+
};
|
116171
|
+
function isFunction$2(arg) {
|
116172
|
+
return typeof arg === "function";
|
116139
116173
|
}
|
116140
|
-
function
|
116141
|
-
return
|
116142
|
-
function errorListener(err2) {
|
116143
|
-
emitter.removeListener(name2, resolver);
|
116144
|
-
reject(err2);
|
116145
|
-
}
|
116146
|
-
function resolver() {
|
116147
|
-
if (typeof emitter.removeListener === "function") {
|
116148
|
-
emitter.removeListener("error", errorListener);
|
116149
|
-
}
|
116150
|
-
resolve2([].slice.call(arguments));
|
116151
|
-
}
|
116152
|
-
eventTargetAgnosticAddListener(emitter, name2, resolver, { once: true });
|
116153
|
-
if (name2 !== "error") {
|
116154
|
-
addErrorHandlerIfEventEmitter(emitter, errorListener, { once: true });
|
116155
|
-
}
|
116156
|
-
});
|
116174
|
+
function isNumber$2(arg) {
|
116175
|
+
return typeof arg === "number";
|
116157
116176
|
}
|
116158
|
-
function
|
116159
|
-
|
116160
|
-
eventTargetAgnosticAddListener(emitter, "error", handler, flags3);
|
116161
|
-
}
|
116177
|
+
function isObject$2(arg) {
|
116178
|
+
return typeof arg === "object" && arg !== null;
|
116162
116179
|
}
|
116163
|
-
function
|
116164
|
-
|
116165
|
-
if (flags3.once) {
|
116166
|
-
emitter.once(name2, listener2);
|
116167
|
-
} else {
|
116168
|
-
emitter.on(name2, listener2);
|
116169
|
-
}
|
116170
|
-
} else if (typeof emitter.addEventListener === "function") {
|
116171
|
-
emitter.addEventListener(name2, function wrapListener(arg) {
|
116172
|
-
if (flags3.once) {
|
116173
|
-
emitter.removeEventListener(name2, wrapListener);
|
116174
|
-
}
|
116175
|
-
listener2(arg);
|
116176
|
-
});
|
116177
|
-
} else {
|
116178
|
-
throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type ' + typeof emitter);
|
116179
|
-
}
|
116180
|
+
function isUndefined(arg) {
|
116181
|
+
return arg === void 0;
|
116180
116182
|
}
|
116181
|
-
var eventsExports = events$3.exports;
|
116182
116183
|
var getRandomValues = typeof crypto != "undefined" && crypto.getRandomValues && crypto.getRandomValues.bind(crypto) || typeof msCrypto != "undefined" && typeof msCrypto.getRandomValues == "function" && msCrypto.getRandomValues.bind(msCrypto);
|
116183
116184
|
var rnds8 = new Uint8Array(16);
|
116184
116185
|
function rng() {
|
@@ -116544,7 +116545,7 @@ const require$$1$3 = /* @__PURE__ */ getAugmentedNamespace(esmBrowser);
|
|
116544
116545
|
value: true
|
116545
116546
|
});
|
116546
116547
|
exports2["default"] = void 0;
|
116547
|
-
var _events = _interopRequireDefault2(
|
116548
|
+
var _events = _interopRequireDefault2(events$3);
|
116548
116549
|
var _uuid = _interopRequireDefault2(require$$1$3);
|
116549
116550
|
function _interopRequireDefault2(obj) {
|
116550
116551
|
return obj && obj.__esModule ? obj : { "default": obj };
|
@@ -117028,7 +117029,7 @@ function rhumbDistance$2(from, to, options) {
|
|
117028
117029
|
}
|
117029
117030
|
function calculateRhumbDistance(origin, destination2, radius2) {
|
117030
117031
|
radius2 = radius2 === void 0 ? helpers_1$9.earthRadius : Number(radius2);
|
117031
|
-
var
|
117032
|
+
var R = radius2;
|
117032
117033
|
var phi12 = origin[1] * Math.PI / 180;
|
117033
117034
|
var phi2 = destination2[1] * Math.PI / 180;
|
117034
117035
|
var DeltaPhi = phi2 - phi12;
|
@@ -117039,7 +117040,7 @@ function calculateRhumbDistance(origin, destination2, radius2) {
|
|
117039
117040
|
var DeltaPsi = Math.log(Math.tan(phi2 / 2 + Math.PI / 4) / Math.tan(phi12 / 2 + Math.PI / 4));
|
117040
117041
|
var q = Math.abs(DeltaPsi) > 1e-11 ? DeltaPhi / DeltaPsi : Math.cos(phi12);
|
117041
117042
|
var delta = Math.sqrt(DeltaPhi * DeltaPhi + q * q * DeltaLambda * DeltaLambda);
|
117042
|
-
var dist2 = delta *
|
117043
|
+
var dist2 = delta * R;
|
117043
117044
|
return dist2;
|
117044
117045
|
}
|
117045
117046
|
js$e.default = rhumbDistance$2;
|
@@ -131586,7 +131587,7 @@ var document_1 = doccy;
|
|
131586
131587
|
value: true
|
131587
131588
|
});
|
131588
131589
|
exports2["default"] = void 0;
|
131589
|
-
var _events =
|
131590
|
+
var _events = events$3;
|
131590
131591
|
var _document = _interopRequireDefault2(document_1);
|
131591
131592
|
var _core = require$$2$2;
|
131592
131593
|
var _deckDrawer = _interopRequireDefault2(deckDrawer);
|
@@ -133507,16 +133508,16 @@ function addDecoder(cases2, importFn) {
|
|
133507
133508
|
}
|
133508
133509
|
cases2.forEach((c2) => registry$1.set(c2, importFn));
|
133509
133510
|
}
|
133510
|
-
addDecoder([void 0, 1], () => import("./raw-
|
133511
|
-
addDecoder(5, () => import("./lzw-
|
133511
|
+
addDecoder([void 0, 1], () => import("./raw-d8d7ab7f.js").then((m2) => m2.default));
|
133512
|
+
addDecoder(5, () => import("./lzw-70f852cc.js").then((m2) => m2.default));
|
133512
133513
|
addDecoder(6, () => {
|
133513
133514
|
throw new Error("old style JPEG compression is not supported.");
|
133514
133515
|
});
|
133515
|
-
addDecoder(7, () => import("./jpeg-
|
133516
|
-
addDecoder([8, 32946], () => import("./deflate-
|
133517
|
-
addDecoder(32773, () => import("./packbits-
|
133518
|
-
addDecoder(34887, () => import("./lerc-
|
133519
|
-
addDecoder(50001, () => import("./webimage-
|
133516
|
+
addDecoder(7, () => import("./jpeg-280f0ee1.js").then((m2) => m2.default));
|
133517
|
+
addDecoder([8, 32946], () => import("./deflate-1679ef33.js").then((m2) => m2.default));
|
133518
|
+
addDecoder(32773, () => import("./packbits-393c67b2.js").then((m2) => m2.default));
|
133519
|
+
addDecoder(34887, () => import("./lerc-12264a36.js").then((m2) => m2.default));
|
133520
|
+
addDecoder(50001, () => import("./webimage-5d24a8e2.js").then((m2) => m2.default));
|
133520
133521
|
function decodeRowAcc(row, stride) {
|
133521
133522
|
let length2 = row.length - stride;
|
133522
133523
|
let offset5 = 0;
|
@@ -133706,16 +133707,16 @@ createCommonjsModule(function(module2) {
|
|
133706
133707
|
if (!new Events2().__proto__)
|
133707
133708
|
prefix2 = false;
|
133708
133709
|
}
|
133709
|
-
function EE(fn, context2,
|
133710
|
+
function EE(fn, context2, once) {
|
133710
133711
|
this.fn = fn;
|
133711
133712
|
this.context = context2;
|
133712
|
-
this.once =
|
133713
|
+
this.once = once || false;
|
133713
133714
|
}
|
133714
|
-
function
|
133715
|
+
function addListener(emitter, event2, fn, context2, once) {
|
133715
133716
|
if (typeof fn !== "function") {
|
133716
133717
|
throw new TypeError("The listener must be a function");
|
133717
133718
|
}
|
133718
|
-
var listener2 = new EE(fn, context2 || emitter,
|
133719
|
+
var listener2 = new EE(fn, context2 || emitter, once), evt = prefix2 ? prefix2 + event2 : event2;
|
133719
133720
|
if (!emitter._events[evt])
|
133720
133721
|
emitter._events[evt] = listener2, emitter._eventsCount++;
|
133721
133722
|
else if (!emitter._events[evt].fn)
|
@@ -133734,7 +133735,7 @@ createCommonjsModule(function(module2) {
|
|
133734
133735
|
this._events = new Events2();
|
133735
133736
|
this._eventsCount = 0;
|
133736
133737
|
}
|
133737
|
-
EventEmitter2.prototype.eventNames = function
|
133738
|
+
EventEmitter2.prototype.eventNames = function eventNames() {
|
133738
133739
|
var names = [], events2, name2;
|
133739
133740
|
if (this._eventsCount === 0)
|
133740
133741
|
return names;
|
@@ -133747,7 +133748,7 @@ createCommonjsModule(function(module2) {
|
|
133747
133748
|
}
|
133748
133749
|
return names;
|
133749
133750
|
};
|
133750
|
-
EventEmitter2.prototype.listeners = function
|
133751
|
+
EventEmitter2.prototype.listeners = function listeners(event2) {
|
133751
133752
|
var evt = prefix2 ? prefix2 + event2 : event2, handlers = this._events[evt];
|
133752
133753
|
if (!handlers)
|
133753
133754
|
return [];
|
@@ -133758,76 +133759,76 @@ createCommonjsModule(function(module2) {
|
|
133758
133759
|
}
|
133759
133760
|
return ee;
|
133760
133761
|
};
|
133761
|
-
EventEmitter2.prototype.listenerCount = function
|
133762
|
-
var evt = prefix2 ? prefix2 + event2 : event2,
|
133763
|
-
if (!
|
133762
|
+
EventEmitter2.prototype.listenerCount = function listenerCount(event2) {
|
133763
|
+
var evt = prefix2 ? prefix2 + event2 : event2, listeners = this._events[evt];
|
133764
|
+
if (!listeners)
|
133764
133765
|
return 0;
|
133765
|
-
if (
|
133766
|
+
if (listeners.fn)
|
133766
133767
|
return 1;
|
133767
|
-
return
|
133768
|
+
return listeners.length;
|
133768
133769
|
};
|
133769
|
-
EventEmitter2.prototype.emit = function
|
133770
|
+
EventEmitter2.prototype.emit = function emit2(event2, a1, a2, a3, a4, a5) {
|
133770
133771
|
var evt = prefix2 ? prefix2 + event2 : event2;
|
133771
133772
|
if (!this._events[evt])
|
133772
133773
|
return false;
|
133773
|
-
var
|
133774
|
-
if (
|
133775
|
-
if (
|
133776
|
-
this.removeListener(event2,
|
133774
|
+
var listeners = this._events[evt], len2 = arguments.length, args, i2;
|
133775
|
+
if (listeners.fn) {
|
133776
|
+
if (listeners.once)
|
133777
|
+
this.removeListener(event2, listeners.fn, void 0, true);
|
133777
133778
|
switch (len2) {
|
133778
133779
|
case 1:
|
133779
|
-
return
|
133780
|
+
return listeners.fn.call(listeners.context), true;
|
133780
133781
|
case 2:
|
133781
|
-
return
|
133782
|
+
return listeners.fn.call(listeners.context, a1), true;
|
133782
133783
|
case 3:
|
133783
|
-
return
|
133784
|
+
return listeners.fn.call(listeners.context, a1, a2), true;
|
133784
133785
|
case 4:
|
133785
|
-
return
|
133786
|
+
return listeners.fn.call(listeners.context, a1, a2, a3), true;
|
133786
133787
|
case 5:
|
133787
|
-
return
|
133788
|
+
return listeners.fn.call(listeners.context, a1, a2, a3, a4), true;
|
133788
133789
|
case 6:
|
133789
|
-
return
|
133790
|
+
return listeners.fn.call(listeners.context, a1, a2, a3, a4, a5), true;
|
133790
133791
|
}
|
133791
133792
|
for (i2 = 1, args = new Array(len2 - 1); i2 < len2; i2++) {
|
133792
133793
|
args[i2 - 1] = arguments[i2];
|
133793
133794
|
}
|
133794
|
-
|
133795
|
+
listeners.fn.apply(listeners.context, args);
|
133795
133796
|
} else {
|
133796
|
-
var length2 =
|
133797
|
+
var length2 = listeners.length, j;
|
133797
133798
|
for (i2 = 0; i2 < length2; i2++) {
|
133798
|
-
if (
|
133799
|
-
this.removeListener(event2,
|
133799
|
+
if (listeners[i2].once)
|
133800
|
+
this.removeListener(event2, listeners[i2].fn, void 0, true);
|
133800
133801
|
switch (len2) {
|
133801
133802
|
case 1:
|
133802
|
-
|
133803
|
+
listeners[i2].fn.call(listeners[i2].context);
|
133803
133804
|
break;
|
133804
133805
|
case 2:
|
133805
|
-
|
133806
|
+
listeners[i2].fn.call(listeners[i2].context, a1);
|
133806
133807
|
break;
|
133807
133808
|
case 3:
|
133808
|
-
|
133809
|
+
listeners[i2].fn.call(listeners[i2].context, a1, a2);
|
133809
133810
|
break;
|
133810
133811
|
case 4:
|
133811
|
-
|
133812
|
+
listeners[i2].fn.call(listeners[i2].context, a1, a2, a3);
|
133812
133813
|
break;
|
133813
133814
|
default:
|
133814
133815
|
if (!args)
|
133815
133816
|
for (j = 1, args = new Array(len2 - 1); j < len2; j++) {
|
133816
133817
|
args[j - 1] = arguments[j];
|
133817
133818
|
}
|
133818
|
-
|
133819
|
+
listeners[i2].fn.apply(listeners[i2].context, args);
|
133819
133820
|
}
|
133820
133821
|
}
|
133821
133822
|
}
|
133822
133823
|
return true;
|
133823
133824
|
};
|
133824
133825
|
EventEmitter2.prototype.on = function on2(event2, fn, context2) {
|
133825
|
-
return
|
133826
|
+
return addListener(this, event2, fn, context2, false);
|
133826
133827
|
};
|
133827
|
-
EventEmitter2.prototype.once = function
|
133828
|
-
return
|
133828
|
+
EventEmitter2.prototype.once = function once(event2, fn, context2) {
|
133829
|
+
return addListener(this, event2, fn, context2, true);
|
133829
133830
|
};
|
133830
|
-
EventEmitter2.prototype.removeListener = function
|
133831
|
+
EventEmitter2.prototype.removeListener = function removeListener(event2, fn, context2, once) {
|
133831
133832
|
var evt = prefix2 ? prefix2 + event2 : event2;
|
133832
133833
|
if (!this._events[evt])
|
133833
133834
|
return this;
|
@@ -133835,15 +133836,15 @@ createCommonjsModule(function(module2) {
|
|
133835
133836
|
clearEvent(this, evt);
|
133836
133837
|
return this;
|
133837
133838
|
}
|
133838
|
-
var
|
133839
|
-
if (
|
133840
|
-
if (
|
133839
|
+
var listeners = this._events[evt];
|
133840
|
+
if (listeners.fn) {
|
133841
|
+
if (listeners.fn === fn && (!once || listeners.once) && (!context2 || listeners.context === context2)) {
|
133841
133842
|
clearEvent(this, evt);
|
133842
133843
|
}
|
133843
133844
|
} else {
|
133844
|
-
for (var i2 = 0, events2 = [], length2 =
|
133845
|
-
if (
|
133846
|
-
events2.push(
|
133845
|
+
for (var i2 = 0, events2 = [], length2 = listeners.length; i2 < length2; i2++) {
|
133846
|
+
if (listeners[i2].fn !== fn || once && !listeners[i2].once || context2 && listeners[i2].context !== context2) {
|
133847
|
+
events2.push(listeners[i2]);
|
133847
133848
|
}
|
133848
133849
|
}
|
133849
133850
|
if (events2.length)
|
@@ -133853,7 +133854,7 @@ createCommonjsModule(function(module2) {
|
|
133853
133854
|
}
|
133854
133855
|
return this;
|
133855
133856
|
};
|
133856
|
-
EventEmitter2.prototype.removeAllListeners = function
|
133857
|
+
EventEmitter2.prototype.removeAllListeners = function removeAllListeners(event2) {
|
133857
133858
|
var evt;
|
133858
133859
|
if (event2) {
|
133859
133860
|
evt = prefix2 ? prefix2 + event2 : event2;
|
@@ -138336,7 +138337,7 @@ var blosc_codec = function() {
|
|
138336
138337
|
b2 += Ga[z2[a2++]];
|
138337
138338
|
return b2;
|
138338
138339
|
}
|
138339
|
-
var Q2 = {},
|
138340
|
+
var Q2 = {}, R = {}, S = {};
|
138340
138341
|
function Ha(a2) {
|
138341
138342
|
if (void 0 === a2)
|
138342
138343
|
return "_unknown";
|
@@ -138381,8 +138382,8 @@ var blosc_codec = function() {
|
|
138381
138382
|
});
|
138382
138383
|
var e3 = Array(a2.length), g2 = [], k = 0;
|
138383
138384
|
a2.forEach(function(h2, l2) {
|
138384
|
-
|
138385
|
-
e3[l2] =
|
138385
|
+
R.hasOwnProperty(h2) ? e3[l2] = R[h2] : (g2.push(h2), Q2.hasOwnProperty(h2) || (Q2[h2] = []), Q2[h2].push(function() {
|
138386
|
+
e3[l2] = R[h2];
|
138386
138387
|
++k;
|
138387
138388
|
k === g2.length && c2(e3);
|
138388
138389
|
}));
|
@@ -138395,12 +138396,12 @@ var blosc_codec = function() {
|
|
138395
138396
|
throw new TypeError("registerType registeredInstance requires argPackAdvance");
|
138396
138397
|
var d = b2.name;
|
138397
138398
|
a2 || T('type "' + d + '" must have a positive integer typeid pointer');
|
138398
|
-
if (
|
138399
|
+
if (R.hasOwnProperty(a2)) {
|
138399
138400
|
if (c2.U)
|
138400
138401
|
return;
|
138401
138402
|
T("Cannot register type '" + d + "' twice");
|
138402
138403
|
}
|
138403
|
-
|
138404
|
+
R[a2] = b2;
|
138404
138405
|
delete S[a2];
|
138405
138406
|
Q2.hasOwnProperty(a2) && (b2 = Q2[a2], delete Q2[a2], b2.forEach(function(e3) {
|
138406
138407
|
e3();
|
@@ -138513,7 +138514,7 @@ var blosc_codec = function() {
|
|
138513
138514
|
}
|
138514
138515
|
function eb(a2, b2) {
|
138515
138516
|
function c2(g2) {
|
138516
|
-
e3[g2] ||
|
138517
|
+
e3[g2] || R[g2] || (S[g2] ? S[g2].forEach(c2) : (d.push(g2), e3[g2] = true));
|
138517
138518
|
}
|
138518
138519
|
var d = [], e3 = {};
|
138519
138520
|
b2.forEach(c2);
|
@@ -138801,7 +138802,7 @@ var blosc_codec = function() {
|
|
138801
138802
|
}, n: Qa, x: function(a2) {
|
138802
138803
|
4 < a2 && (V[a2].P += 1);
|
138803
138804
|
}, C: function(a2, b2) {
|
138804
|
-
var c2 =
|
138805
|
+
var c2 = R[a2];
|
138805
138806
|
void 0 === c2 && T("_emval_take_value has unknown type " + cb(a2));
|
138806
138807
|
a2 = c2.readValueFromPointer(b2);
|
138807
138808
|
return Ra(a2);
|
@@ -141269,7 +141270,7 @@ const channels = {
|
|
141269
141270
|
},
|
141270
141271
|
fs: fs$2
|
141271
141272
|
};
|
141272
|
-
function range$
|
141273
|
+
function range$6(len2) {
|
141273
141274
|
return [...Array(len2).keys()];
|
141274
141275
|
}
|
141275
141276
|
function padWithDefault$2(arr, defaultValue2, padWidth) {
|
@@ -142373,7 +142374,7 @@ const ScaleBarLayer = class extends CompositeLayer {
|
|
142373
142374
|
sizeScale: 2 ** -zoom2,
|
142374
142375
|
characterSet: [
|
142375
142376
|
...displayUnit.split(""),
|
142376
|
-
...range$
|
142377
|
+
...range$6(10).map((i2) => String(i2)),
|
142377
142378
|
".",
|
142378
142379
|
"e",
|
142379
142380
|
"+"
|
@@ -143697,7 +143698,7 @@ function deviation$1(values2, valueof) {
|
|
143697
143698
|
const v = variance$1(values2, valueof);
|
143698
143699
|
return v ? Math.sqrt(v) : v;
|
143699
143700
|
}
|
143700
|
-
function
|
143701
|
+
function d3_extent(values2, valueof) {
|
143701
143702
|
let min2;
|
143702
143703
|
let max2;
|
143703
143704
|
if (valueof === void 0) {
|
@@ -143732,6 +143733,47 @@ function extent$1(values2, valueof) {
|
|
143732
143733
|
}
|
143733
143734
|
return [min2, max2];
|
143734
143735
|
}
|
143736
|
+
class Adder {
|
143737
|
+
constructor() {
|
143738
|
+
this._partials = new Float64Array(32);
|
143739
|
+
this._n = 0;
|
143740
|
+
}
|
143741
|
+
add(x2) {
|
143742
|
+
const p = this._partials;
|
143743
|
+
let i2 = 0;
|
143744
|
+
for (let j = 0; j < this._n && j < 32; j++) {
|
143745
|
+
const y2 = p[j], hi = x2 + y2, lo = Math.abs(x2) < Math.abs(y2) ? x2 - (hi - y2) : y2 - (hi - x2);
|
143746
|
+
if (lo)
|
143747
|
+
p[i2++] = lo;
|
143748
|
+
x2 = hi;
|
143749
|
+
}
|
143750
|
+
p[i2] = x2;
|
143751
|
+
this._n = i2 + 1;
|
143752
|
+
return this;
|
143753
|
+
}
|
143754
|
+
valueOf() {
|
143755
|
+
const p = this._partials;
|
143756
|
+
let n2 = this._n, x2, y2, lo, hi = 0;
|
143757
|
+
if (n2 > 0) {
|
143758
|
+
hi = p[--n2];
|
143759
|
+
while (n2 > 0) {
|
143760
|
+
x2 = hi;
|
143761
|
+
y2 = p[--n2];
|
143762
|
+
hi = x2 + y2;
|
143763
|
+
lo = y2 - (hi - x2);
|
143764
|
+
if (lo)
|
143765
|
+
break;
|
143766
|
+
}
|
143767
|
+
if (n2 > 0 && (lo < 0 && p[n2 - 1] < 0 || lo > 0 && p[n2 - 1] > 0)) {
|
143768
|
+
y2 = lo * 2;
|
143769
|
+
x2 = hi + y2;
|
143770
|
+
if (y2 == x2 - hi)
|
143771
|
+
hi = x2;
|
143772
|
+
}
|
143773
|
+
}
|
143774
|
+
return hi;
|
143775
|
+
}
|
143776
|
+
}
|
143735
143777
|
class InternMap2 extends Map {
|
143736
143778
|
constructor(entries2, key2 = keyof) {
|
143737
143779
|
super();
|
@@ -143810,14 +143852,14 @@ function constant$8(x2) {
|
|
143810
143852
|
};
|
143811
143853
|
}
|
143812
143854
|
var e10$1 = Math.sqrt(50), e5$1 = Math.sqrt(10), e2$1 = Math.sqrt(2);
|
143813
|
-
function ticks
|
143855
|
+
function ticks(start, stop3, count2) {
|
143814
143856
|
var reverse2, i2 = -1, n2, ticks2, step;
|
143815
143857
|
stop3 = +stop3, start = +start, count2 = +count2;
|
143816
143858
|
if (start === stop3 && count2 > 0)
|
143817
143859
|
return [start];
|
143818
143860
|
if (reverse2 = stop3 < start)
|
143819
143861
|
n2 = start, start = stop3, stop3 = n2;
|
143820
|
-
if ((step = tickIncrement
|
143862
|
+
if ((step = tickIncrement(start, stop3, count2)) === 0 || !isFinite(step))
|
143821
143863
|
return [];
|
143822
143864
|
if (step > 0) {
|
143823
143865
|
let r0 = Math.round(start / step), r1 = Math.round(stop3 / step);
|
@@ -143843,7 +143885,7 @@ function ticks$1(start, stop3, count2) {
|
|
143843
143885
|
ticks2.reverse();
|
143844
143886
|
return ticks2;
|
143845
143887
|
}
|
143846
|
-
function tickIncrement
|
143888
|
+
function tickIncrement(start, stop3, count2) {
|
143847
143889
|
var step = (stop3 - start) / Math.max(0, count2), power = Math.floor(Math.log(step) / Math.LN10), error2 = step / Math.pow(10, power);
|
143848
143890
|
return power >= 0 ? (error2 >= e10$1 ? 10 : error2 >= e5$1 ? 5 : error2 >= e2$1 ? 2 : 1) * Math.pow(10, power) : -Math.pow(10, -power) / (error2 >= e10$1 ? 10 : error2 >= e5$1 ? 5 : error2 >= e2$1 ? 2 : 1);
|
143849
143891
|
}
|
@@ -143860,7 +143902,7 @@ function tickStep$1(start, stop3, count2) {
|
|
143860
143902
|
function nice$3(start, stop3, count2) {
|
143861
143903
|
let prestep;
|
143862
143904
|
while (true) {
|
143863
|
-
const step = tickIncrement
|
143905
|
+
const step = tickIncrement(start, stop3, count2);
|
143864
143906
|
if (step === prestep || step === 0 || !isFinite(step)) {
|
143865
143907
|
return [start, stop3];
|
143866
143908
|
} else if (step > 0) {
|
@@ -143877,7 +143919,7 @@ function sturges(values2) {
|
|
143877
143919
|
return Math.ceil(Math.log(count$1(values2)) / Math.LN2) + 1;
|
143878
143920
|
}
|
143879
143921
|
function bin$3() {
|
143880
|
-
var value2 = identity$c, domain2 =
|
143922
|
+
var value2 = identity$c, domain2 = d3_extent, threshold2 = sturges;
|
143881
143923
|
function histogram(data2) {
|
143882
143924
|
if (!Array.isArray(data2))
|
143883
143925
|
data2 = Array.from(data2);
|
@@ -143888,12 +143930,12 @@ function bin$3() {
|
|
143888
143930
|
var xz = domain2(values2), x02 = xz[0], x12 = xz[1], tz = threshold2(values2, x02, x12);
|
143889
143931
|
if (!Array.isArray(tz)) {
|
143890
143932
|
const max2 = x12, tn = +tz;
|
143891
|
-
if (domain2 ===
|
143933
|
+
if (domain2 === d3_extent)
|
143892
143934
|
[x02, x12] = nice$3(x02, x12, tn);
|
143893
|
-
tz = ticks
|
143935
|
+
tz = ticks(x02, x12, tn);
|
143894
143936
|
if (tz[tz.length - 1] >= x12) {
|
143895
|
-
if (max2 >= x12 && domain2 ===
|
143896
|
-
const step = tickIncrement
|
143937
|
+
if (max2 >= x12 && domain2 === d3_extent) {
|
143938
|
+
const step = tickIncrement(x02, x12, tn);
|
143897
143939
|
if (isFinite(step)) {
|
143898
143940
|
if (step > 0) {
|
143899
143941
|
x12 = (Math.floor(x12 / step) + 1) * step;
|
@@ -144002,7 +144044,15 @@ function mean$1(values2, valueof) {
|
|
144002
144044
|
if (count2)
|
144003
144045
|
return sum2 / count2;
|
144004
144046
|
}
|
144005
|
-
function
|
144047
|
+
function* flatten(arrays) {
|
144048
|
+
for (const array2 of arrays) {
|
144049
|
+
yield* array2;
|
144050
|
+
}
|
144051
|
+
}
|
144052
|
+
function merge$3(arrays) {
|
144053
|
+
return Array.from(flatten(arrays));
|
144054
|
+
}
|
144055
|
+
function range$5(start, stop3, step) {
|
144006
144056
|
start = +start, stop3 = +stop3, step = (n2 = arguments.length) < 2 ? (stop3 = start, start = 0, 1) : n2 < 3 ? 1 : +step;
|
144007
144057
|
var i2 = -1, n2 = Math.max(0, Math.ceil((stop3 - start) / step)) | 0, range2 = new Array(n2);
|
144008
144058
|
while (++i2 < n2) {
|
@@ -144029,7 +144079,7 @@ function sum$2(values2, valueof) {
|
|
144029
144079
|
return sum2;
|
144030
144080
|
}
|
144031
144081
|
function normalize$4(arr) {
|
144032
|
-
const [min2, max2] =
|
144082
|
+
const [min2, max2] = d3_extent(arr);
|
144033
144083
|
const ratio = 255 / (max2 - min2);
|
144034
144084
|
const data2 = new Uint8Array(arr.map((i2) => Math.floor((i2 - min2) * ratio)));
|
144035
144085
|
return data2;
|
@@ -144250,7 +144300,7 @@ class BitmaskLayer2 extends XRLayer {
|
|
144250
144300
|
} = this.state;
|
144251
144301
|
if (textures && model) {
|
144252
144302
|
const scaleFactor = 1 / 2 ** (maxZoom - zoom2);
|
144253
|
-
const colors2 = Object.fromEntries(range$
|
144303
|
+
const colors2 = Object.fromEntries(range$c(MAX_CHANNELS).map((i2) => [`color${i2}`, getColor(channelColors[i2])]));
|
144254
144304
|
model.setUniforms(Object.assign({}, uniforms, {
|
144255
144305
|
...colors2,
|
144256
144306
|
// Bitmask image channel data textures
|
@@ -144513,377 +144563,6 @@ function CellSetExpressionPlotOptions(props) {
|
|
144513
144563
|
] }, "transform-coefficient-option-row") : null
|
144514
144564
|
] });
|
144515
144565
|
}
|
144516
|
-
function ascending$4(a2, b2) {
|
144517
|
-
return a2 == null || b2 == null ? NaN : a2 < b2 ? -1 : a2 > b2 ? 1 : a2 >= b2 ? 0 : NaN;
|
144518
|
-
}
|
144519
|
-
function descending$1(a2, b2) {
|
144520
|
-
return a2 == null || b2 == null ? NaN : b2 < a2 ? -1 : b2 > a2 ? 1 : b2 >= a2 ? 0 : NaN;
|
144521
|
-
}
|
144522
|
-
function bisector$1(f2) {
|
144523
|
-
let compare12, compare2, delta;
|
144524
|
-
if (f2.length !== 2) {
|
144525
|
-
compare12 = ascending$4;
|
144526
|
-
compare2 = (d, x2) => ascending$4(f2(d), x2);
|
144527
|
-
delta = (d, x2) => f2(d) - x2;
|
144528
|
-
} else {
|
144529
|
-
compare12 = f2 === ascending$4 || f2 === descending$1 ? f2 : zero$6;
|
144530
|
-
compare2 = f2;
|
144531
|
-
delta = f2;
|
144532
|
-
}
|
144533
|
-
function left2(a2, x2, lo = 0, hi = a2.length) {
|
144534
|
-
if (lo < hi) {
|
144535
|
-
if (compare12(x2, x2) !== 0)
|
144536
|
-
return hi;
|
144537
|
-
do {
|
144538
|
-
const mid = lo + hi >>> 1;
|
144539
|
-
if (compare2(a2[mid], x2) < 0)
|
144540
|
-
lo = mid + 1;
|
144541
|
-
else
|
144542
|
-
hi = mid;
|
144543
|
-
} while (lo < hi);
|
144544
|
-
}
|
144545
|
-
return lo;
|
144546
|
-
}
|
144547
|
-
function right2(a2, x2, lo = 0, hi = a2.length) {
|
144548
|
-
if (lo < hi) {
|
144549
|
-
if (compare12(x2, x2) !== 0)
|
144550
|
-
return hi;
|
144551
|
-
do {
|
144552
|
-
const mid = lo + hi >>> 1;
|
144553
|
-
if (compare2(a2[mid], x2) <= 0)
|
144554
|
-
lo = mid + 1;
|
144555
|
-
else
|
144556
|
-
hi = mid;
|
144557
|
-
} while (lo < hi);
|
144558
|
-
}
|
144559
|
-
return lo;
|
144560
|
-
}
|
144561
|
-
function center2(a2, x2, lo = 0, hi = a2.length) {
|
144562
|
-
const i2 = left2(a2, x2, lo, hi - 1);
|
144563
|
-
return i2 > lo && delta(a2[i2 - 1], x2) > -delta(a2[i2], x2) ? i2 - 1 : i2;
|
144564
|
-
}
|
144565
|
-
return { left: left2, center: center2, right: right2 };
|
144566
|
-
}
|
144567
|
-
function zero$6() {
|
144568
|
-
return 0;
|
144569
|
-
}
|
144570
|
-
function number$a(x2) {
|
144571
|
-
return x2 === null ? NaN : +x2;
|
144572
|
-
}
|
144573
|
-
function* numbers$3(values2, valueof) {
|
144574
|
-
if (valueof === void 0) {
|
144575
|
-
for (let value2 of values2) {
|
144576
|
-
if (value2 != null && (value2 = +value2) >= value2) {
|
144577
|
-
yield value2;
|
144578
|
-
}
|
144579
|
-
}
|
144580
|
-
} else {
|
144581
|
-
let index2 = -1;
|
144582
|
-
for (let value2 of values2) {
|
144583
|
-
if ((value2 = valueof(value2, ++index2, values2)) != null && (value2 = +value2) >= value2) {
|
144584
|
-
yield value2;
|
144585
|
-
}
|
144586
|
-
}
|
144587
|
-
}
|
144588
|
-
}
|
144589
|
-
const ascendingBisect = bisector$1(ascending$4);
|
144590
|
-
const bisectRight$1 = ascendingBisect.right;
|
144591
|
-
const bisectLeft$1 = ascendingBisect.left;
|
144592
|
-
bisector$1(number$a).center;
|
144593
|
-
const bisect$1 = bisectRight$1;
|
144594
|
-
function variance(values2, valueof) {
|
144595
|
-
let count2 = 0;
|
144596
|
-
let delta;
|
144597
|
-
let mean2 = 0;
|
144598
|
-
let sum2 = 0;
|
144599
|
-
if (valueof === void 0) {
|
144600
|
-
for (let value2 of values2) {
|
144601
|
-
if (value2 != null && (value2 = +value2) >= value2) {
|
144602
|
-
delta = value2 - mean2;
|
144603
|
-
mean2 += delta / ++count2;
|
144604
|
-
sum2 += delta * (value2 - mean2);
|
144605
|
-
}
|
144606
|
-
}
|
144607
|
-
} else {
|
144608
|
-
let index2 = -1;
|
144609
|
-
for (let value2 of values2) {
|
144610
|
-
if ((value2 = valueof(value2, ++index2, values2)) != null && (value2 = +value2) >= value2) {
|
144611
|
-
delta = value2 - mean2;
|
144612
|
-
mean2 += delta / ++count2;
|
144613
|
-
sum2 += delta * (value2 - mean2);
|
144614
|
-
}
|
144615
|
-
}
|
144616
|
-
}
|
144617
|
-
if (count2 > 1)
|
144618
|
-
return sum2 / (count2 - 1);
|
144619
|
-
}
|
144620
|
-
function deviation(values2, valueof) {
|
144621
|
-
const v = variance(values2, valueof);
|
144622
|
-
return v ? Math.sqrt(v) : v;
|
144623
|
-
}
|
144624
|
-
class Adder {
|
144625
|
-
constructor() {
|
144626
|
-
this._partials = new Float64Array(32);
|
144627
|
-
this._n = 0;
|
144628
|
-
}
|
144629
|
-
add(x2) {
|
144630
|
-
const p = this._partials;
|
144631
|
-
let i2 = 0;
|
144632
|
-
for (let j = 0; j < this._n && j < 32; j++) {
|
144633
|
-
const y2 = p[j], hi = x2 + y2, lo = Math.abs(x2) < Math.abs(y2) ? x2 - (hi - y2) : y2 - (hi - x2);
|
144634
|
-
if (lo)
|
144635
|
-
p[i2++] = lo;
|
144636
|
-
x2 = hi;
|
144637
|
-
}
|
144638
|
-
p[i2] = x2;
|
144639
|
-
this._n = i2 + 1;
|
144640
|
-
return this;
|
144641
|
-
}
|
144642
|
-
valueOf() {
|
144643
|
-
const p = this._partials;
|
144644
|
-
let n2 = this._n, x2, y2, lo, hi = 0;
|
144645
|
-
if (n2 > 0) {
|
144646
|
-
hi = p[--n2];
|
144647
|
-
while (n2 > 0) {
|
144648
|
-
x2 = hi;
|
144649
|
-
y2 = p[--n2];
|
144650
|
-
hi = x2 + y2;
|
144651
|
-
lo = y2 - (hi - x2);
|
144652
|
-
if (lo)
|
144653
|
-
break;
|
144654
|
-
}
|
144655
|
-
if (n2 > 0 && (lo < 0 && p[n2 - 1] < 0 || lo > 0 && p[n2 - 1] > 0)) {
|
144656
|
-
y2 = lo * 2;
|
144657
|
-
x2 = hi + y2;
|
144658
|
-
if (y2 == x2 - hi)
|
144659
|
-
hi = x2;
|
144660
|
-
}
|
144661
|
-
}
|
144662
|
-
return hi;
|
144663
|
-
}
|
144664
|
-
}
|
144665
|
-
function permute(source2, keys3) {
|
144666
|
-
return Array.from(keys3, (key2) => source2[key2]);
|
144667
|
-
}
|
144668
|
-
function compareDefined(compare2 = ascending$4) {
|
144669
|
-
if (compare2 === ascending$4)
|
144670
|
-
return ascendingDefined;
|
144671
|
-
if (typeof compare2 !== "function")
|
144672
|
-
throw new TypeError("compare is not a function");
|
144673
|
-
return (a2, b2) => {
|
144674
|
-
const x2 = compare2(a2, b2);
|
144675
|
-
if (x2 || x2 === 0)
|
144676
|
-
return x2;
|
144677
|
-
return (compare2(b2, b2) === 0) - (compare2(a2, a2) === 0);
|
144678
|
-
};
|
144679
|
-
}
|
144680
|
-
function ascendingDefined(a2, b2) {
|
144681
|
-
return (a2 == null || !(a2 >= a2)) - (b2 == null || !(b2 >= b2)) || (a2 < b2 ? -1 : a2 > b2 ? 1 : 0);
|
144682
|
-
}
|
144683
|
-
var e10 = Math.sqrt(50), e5 = Math.sqrt(10), e2 = Math.sqrt(2);
|
144684
|
-
function ticks(start, stop3, count2) {
|
144685
|
-
var reverse2, i2 = -1, n2, ticks2, step;
|
144686
|
-
stop3 = +stop3, start = +start, count2 = +count2;
|
144687
|
-
if (start === stop3 && count2 > 0)
|
144688
|
-
return [start];
|
144689
|
-
if (reverse2 = stop3 < start)
|
144690
|
-
n2 = start, start = stop3, stop3 = n2;
|
144691
|
-
if ((step = tickIncrement(start, stop3, count2)) === 0 || !isFinite(step))
|
144692
|
-
return [];
|
144693
|
-
if (step > 0) {
|
144694
|
-
let r0 = Math.round(start / step), r1 = Math.round(stop3 / step);
|
144695
|
-
if (r0 * step < start)
|
144696
|
-
++r0;
|
144697
|
-
if (r1 * step > stop3)
|
144698
|
-
--r1;
|
144699
|
-
ticks2 = new Array(n2 = r1 - r0 + 1);
|
144700
|
-
while (++i2 < n2)
|
144701
|
-
ticks2[i2] = (r0 + i2) * step;
|
144702
|
-
} else {
|
144703
|
-
step = -step;
|
144704
|
-
let r0 = Math.round(start * step), r1 = Math.round(stop3 * step);
|
144705
|
-
if (r0 / step < start)
|
144706
|
-
++r0;
|
144707
|
-
if (r1 / step > stop3)
|
144708
|
-
--r1;
|
144709
|
-
ticks2 = new Array(n2 = r1 - r0 + 1);
|
144710
|
-
while (++i2 < n2)
|
144711
|
-
ticks2[i2] = (r0 + i2) / step;
|
144712
|
-
}
|
144713
|
-
if (reverse2)
|
144714
|
-
ticks2.reverse();
|
144715
|
-
return ticks2;
|
144716
|
-
}
|
144717
|
-
function tickIncrement(start, stop3, count2) {
|
144718
|
-
var step = (stop3 - start) / Math.max(0, count2), power = Math.floor(Math.log(step) / Math.LN10), error2 = step / Math.pow(10, power);
|
144719
|
-
return power >= 0 ? (error2 >= e10 ? 10 : error2 >= e5 ? 5 : error2 >= e2 ? 2 : 1) * Math.pow(10, power) : -Math.pow(10, -power) / (error2 >= e10 ? 10 : error2 >= e5 ? 5 : error2 >= e2 ? 2 : 1);
|
144720
|
-
}
|
144721
|
-
function tickStep(start, stop3, count2) {
|
144722
|
-
var step0 = Math.abs(stop3 - start) / Math.max(0, count2), step1 = Math.pow(10, Math.floor(Math.log(step0) / Math.LN10)), error2 = step0 / step1;
|
144723
|
-
if (error2 >= e10)
|
144724
|
-
step1 *= 10;
|
144725
|
-
else if (error2 >= e5)
|
144726
|
-
step1 *= 5;
|
144727
|
-
else if (error2 >= e2)
|
144728
|
-
step1 *= 2;
|
144729
|
-
return stop3 < start ? -step1 : step1;
|
144730
|
-
}
|
144731
|
-
function max$2(values2, valueof) {
|
144732
|
-
let max2;
|
144733
|
-
if (valueof === void 0) {
|
144734
|
-
for (const value2 of values2) {
|
144735
|
-
if (value2 != null && (max2 < value2 || max2 === void 0 && value2 >= value2)) {
|
144736
|
-
max2 = value2;
|
144737
|
-
}
|
144738
|
-
}
|
144739
|
-
} else {
|
144740
|
-
let index2 = -1;
|
144741
|
-
for (let value2 of values2) {
|
144742
|
-
if ((value2 = valueof(value2, ++index2, values2)) != null && (max2 < value2 || max2 === void 0 && value2 >= value2)) {
|
144743
|
-
max2 = value2;
|
144744
|
-
}
|
144745
|
-
}
|
144746
|
-
}
|
144747
|
-
return max2;
|
144748
|
-
}
|
144749
|
-
function min$2(values2, valueof) {
|
144750
|
-
let min2;
|
144751
|
-
if (valueof === void 0) {
|
144752
|
-
for (const value2 of values2) {
|
144753
|
-
if (value2 != null && (min2 > value2 || min2 === void 0 && value2 >= value2)) {
|
144754
|
-
min2 = value2;
|
144755
|
-
}
|
144756
|
-
}
|
144757
|
-
} else {
|
144758
|
-
let index2 = -1;
|
144759
|
-
for (let value2 of values2) {
|
144760
|
-
if ((value2 = valueof(value2, ++index2, values2)) != null && (min2 > value2 || min2 === void 0 && value2 >= value2)) {
|
144761
|
-
min2 = value2;
|
144762
|
-
}
|
144763
|
-
}
|
144764
|
-
}
|
144765
|
-
return min2;
|
144766
|
-
}
|
144767
|
-
function quickselect(array2, k, left2 = 0, right2 = array2.length - 1, compare2) {
|
144768
|
-
compare2 = compare2 === void 0 ? ascendingDefined : compareDefined(compare2);
|
144769
|
-
while (right2 > left2) {
|
144770
|
-
if (right2 - left2 > 600) {
|
144771
|
-
const n2 = right2 - left2 + 1;
|
144772
|
-
const m2 = k - left2 + 1;
|
144773
|
-
const z2 = Math.log(n2);
|
144774
|
-
const s2 = 0.5 * Math.exp(2 * z2 / 3);
|
144775
|
-
const sd = 0.5 * Math.sqrt(z2 * s2 * (n2 - s2) / n2) * (m2 - n2 / 2 < 0 ? -1 : 1);
|
144776
|
-
const newLeft = Math.max(left2, Math.floor(k - m2 * s2 / n2 + sd));
|
144777
|
-
const newRight = Math.min(right2, Math.floor(k + (n2 - m2) * s2 / n2 + sd));
|
144778
|
-
quickselect(array2, k, newLeft, newRight, compare2);
|
144779
|
-
}
|
144780
|
-
const t4 = array2[k];
|
144781
|
-
let i2 = left2;
|
144782
|
-
let j = right2;
|
144783
|
-
swap$1(array2, left2, k);
|
144784
|
-
if (compare2(array2[right2], t4) > 0)
|
144785
|
-
swap$1(array2, left2, right2);
|
144786
|
-
while (i2 < j) {
|
144787
|
-
swap$1(array2, i2, j), ++i2, --j;
|
144788
|
-
while (compare2(array2[i2], t4) < 0)
|
144789
|
-
++i2;
|
144790
|
-
while (compare2(array2[j], t4) > 0)
|
144791
|
-
--j;
|
144792
|
-
}
|
144793
|
-
if (compare2(array2[left2], t4) === 0)
|
144794
|
-
swap$1(array2, left2, j);
|
144795
|
-
else
|
144796
|
-
++j, swap$1(array2, j, right2);
|
144797
|
-
if (j <= k)
|
144798
|
-
left2 = j + 1;
|
144799
|
-
if (k <= j)
|
144800
|
-
right2 = j - 1;
|
144801
|
-
}
|
144802
|
-
return array2;
|
144803
|
-
}
|
144804
|
-
function swap$1(array2, i2, j) {
|
144805
|
-
const t4 = array2[i2];
|
144806
|
-
array2[i2] = array2[j];
|
144807
|
-
array2[j] = t4;
|
144808
|
-
}
|
144809
|
-
function quantile$2(values2, p, valueof) {
|
144810
|
-
values2 = Float64Array.from(numbers$3(values2, valueof));
|
144811
|
-
if (!(n2 = values2.length))
|
144812
|
-
return;
|
144813
|
-
if ((p = +p) <= 0 || n2 < 2)
|
144814
|
-
return min$2(values2);
|
144815
|
-
if (p >= 1)
|
144816
|
-
return max$2(values2);
|
144817
|
-
var n2, i2 = (n2 - 1) * p, i0 = Math.floor(i2), value0 = max$2(quickselect(values2, i0).subarray(0, i0 + 1)), value1 = min$2(values2.subarray(i0 + 1));
|
144818
|
-
return value0 + (value1 - value0) * (i2 - i0);
|
144819
|
-
}
|
144820
|
-
function quantileSorted(values2, p, valueof = number$a) {
|
144821
|
-
if (!(n2 = values2.length))
|
144822
|
-
return;
|
144823
|
-
if ((p = +p) <= 0 || n2 < 2)
|
144824
|
-
return +valueof(values2[0], 0, values2);
|
144825
|
-
if (p >= 1)
|
144826
|
-
return +valueof(values2[n2 - 1], n2 - 1, values2);
|
144827
|
-
var n2, i2 = (n2 - 1) * p, i0 = Math.floor(i2), value0 = +valueof(values2[i0], i0, values2), value1 = +valueof(values2[i0 + 1], i0 + 1, values2);
|
144828
|
-
return value0 + (value1 - value0) * (i2 - i0);
|
144829
|
-
}
|
144830
|
-
function mean(values2, valueof) {
|
144831
|
-
let count2 = 0;
|
144832
|
-
let sum2 = 0;
|
144833
|
-
if (valueof === void 0) {
|
144834
|
-
for (let value2 of values2) {
|
144835
|
-
if (value2 != null && (value2 = +value2) >= value2) {
|
144836
|
-
++count2, sum2 += value2;
|
144837
|
-
}
|
144838
|
-
}
|
144839
|
-
} else {
|
144840
|
-
let index2 = -1;
|
144841
|
-
for (let value2 of values2) {
|
144842
|
-
if ((value2 = valueof(value2, ++index2, values2)) != null && (value2 = +value2) >= value2) {
|
144843
|
-
++count2, sum2 += value2;
|
144844
|
-
}
|
144845
|
-
}
|
144846
|
-
}
|
144847
|
-
if (count2)
|
144848
|
-
return sum2 / count2;
|
144849
|
-
}
|
144850
|
-
function median(values2, valueof) {
|
144851
|
-
return quantile$2(values2, 0.5, valueof);
|
144852
|
-
}
|
144853
|
-
function* flatten(arrays) {
|
144854
|
-
for (const array2 of arrays) {
|
144855
|
-
yield* array2;
|
144856
|
-
}
|
144857
|
-
}
|
144858
|
-
function merge$3(arrays) {
|
144859
|
-
return Array.from(flatten(arrays));
|
144860
|
-
}
|
144861
|
-
function range$4(start, stop3, step) {
|
144862
|
-
start = +start, stop3 = +stop3, step = (n2 = arguments.length) < 2 ? (stop3 = start, start = 0, 1) : n2 < 3 ? 1 : +step;
|
144863
|
-
var i2 = -1, n2 = Math.max(0, Math.ceil((stop3 - start) / step)) | 0, range2 = new Array(n2);
|
144864
|
-
while (++i2 < n2) {
|
144865
|
-
range2[i2] = start + i2 * step;
|
144866
|
-
}
|
144867
|
-
return range2;
|
144868
|
-
}
|
144869
|
-
function sum$1(values2, valueof) {
|
144870
|
-
let sum2 = 0;
|
144871
|
-
if (valueof === void 0) {
|
144872
|
-
for (let value2 of values2) {
|
144873
|
-
if (value2 = +value2) {
|
144874
|
-
sum2 += value2;
|
144875
|
-
}
|
144876
|
-
}
|
144877
|
-
} else {
|
144878
|
-
let index2 = -1;
|
144879
|
-
for (let value2 of values2) {
|
144880
|
-
if (value2 = +valueof(value2, ++index2, values2)) {
|
144881
|
-
sum2 += value2;
|
144882
|
-
}
|
144883
|
-
}
|
144884
|
-
}
|
144885
|
-
return sum2;
|
144886
|
-
}
|
144887
144566
|
function initRange$1(domain2, range2) {
|
144888
144567
|
switch (arguments.length) {
|
144889
144568
|
case 0:
|
@@ -144921,7 +144600,7 @@ function initInterpolator$1(domain2, interpolator) {
|
|
144921
144600
|
}
|
144922
144601
|
const implicit$1 = Symbol("implicit");
|
144923
144602
|
function ordinal$1() {
|
144924
|
-
var index2 = new
|
144603
|
+
var index2 = new InternMap2(), domain2 = [], range2 = [], unknown = implicit$1;
|
144925
144604
|
function scale2(d) {
|
144926
144605
|
let i2 = index2.get(d);
|
144927
144606
|
if (i2 === void 0) {
|
@@ -144934,7 +144613,7 @@ function ordinal$1() {
|
|
144934
144613
|
scale2.domain = function(_) {
|
144935
144614
|
if (!arguments.length)
|
144936
144615
|
return domain2.slice();
|
144937
|
-
domain2 = [], index2 = new
|
144616
|
+
domain2 = [], index2 = new InternMap2();
|
144938
144617
|
for (const value2 of _) {
|
144939
144618
|
if (index2.has(value2))
|
144940
144619
|
continue;
|
@@ -145575,7 +145254,7 @@ function object$3(a2, b2) {
|
|
145575
145254
|
};
|
145576
145255
|
}
|
145577
145256
|
var reA$2 = /[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g, reB$2 = new RegExp(reA$2.source, "g");
|
145578
|
-
function zero$
|
145257
|
+
function zero$6(b2) {
|
145579
145258
|
return function() {
|
145580
145259
|
return b2;
|
145581
145260
|
};
|
@@ -145614,7 +145293,7 @@ function string$2(a2, b2) {
|
|
145614
145293
|
else
|
145615
145294
|
s2[++i2] = bs;
|
145616
145295
|
}
|
145617
|
-
return s2.length < 2 ? q[0] ? one$4(q[0].x) : zero$
|
145296
|
+
return s2.length < 2 ? q[0] ? one$4(q[0].x) : zero$6(b2) : (b2 = q.length, function(t4) {
|
145618
145297
|
for (var i22 = 0, o2; i22 < b2; ++i22)
|
145619
145298
|
s2[(o2 = q[i22]).i] = o2.x(t4);
|
145620
145299
|
return s2.join("");
|
@@ -145894,7 +145573,7 @@ function constants$2(x2) {
|
|
145894
145573
|
return x2;
|
145895
145574
|
};
|
145896
145575
|
}
|
145897
|
-
function number$
|
145576
|
+
function number$a(x2) {
|
145898
145577
|
return +x2;
|
145899
145578
|
}
|
145900
145579
|
var unit$1 = [0, 1];
|
@@ -145935,7 +145614,7 @@ function polymap$1(domain2, range2, interpolate2) {
|
|
145935
145614
|
r3[i2] = interpolate2(range2[i2], range2[i2 + 1]);
|
145936
145615
|
}
|
145937
145616
|
return function(x2) {
|
145938
|
-
var i22 = bisect$
|
145617
|
+
var i22 = bisect$2(domain2, x2, 1, j) - 1;
|
145939
145618
|
return r3[i22](d[i22](x2));
|
145940
145619
|
};
|
145941
145620
|
}
|
@@ -145959,7 +145638,7 @@ function transformer$6() {
|
|
145959
145638
|
return clamp2(untransform((input || (input = piecewise2(range2, domain2.map(transform2), interpolateNumber$1)))(y2)));
|
145960
145639
|
};
|
145961
145640
|
scale2.domain = function(_) {
|
145962
|
-
return arguments.length ? (domain2 = Array.from(_, number$
|
145641
|
+
return arguments.length ? (domain2 = Array.from(_, number$a), rescale()) : domain2.slice();
|
145963
145642
|
};
|
145964
145643
|
scale2.range = function(_) {
|
145965
145644
|
return arguments.length ? (range2 = Array.from(_), rescale()) : range2.slice();
|
@@ -146212,7 +145891,7 @@ function precisionRound$1(step, max2) {
|
|
146212
145891
|
return Math.max(0, exponent$1(max2) - exponent$1(step)) + 1;
|
146213
145892
|
}
|
146214
145893
|
function tickFormat$2(start, stop3, count2, specifier) {
|
146215
|
-
var step = tickStep(start, stop3, count2), precision;
|
145894
|
+
var step = tickStep$1(start, stop3, count2), precision;
|
146216
145895
|
specifier = formatSpecifier$1(specifier == null ? ",f" : specifier);
|
146217
145896
|
switch (specifier.type) {
|
146218
145897
|
case "s": {
|
@@ -146300,7 +145979,7 @@ function identity$8(domain2) {
|
|
146300
145979
|
}
|
146301
145980
|
scale2.invert = scale2;
|
146302
145981
|
scale2.domain = scale2.range = function(_) {
|
146303
|
-
return arguments.length ? (domain2 = Array.from(_, number$
|
145982
|
+
return arguments.length ? (domain2 = Array.from(_, number$a), scale2) : domain2.slice();
|
146304
145983
|
};
|
146305
145984
|
scale2.unknown = function(_) {
|
146306
145985
|
return arguments.length ? (unknown = _, scale2) : unknown;
|
@@ -146308,7 +145987,7 @@ function identity$8(domain2) {
|
|
146308
145987
|
scale2.copy = function() {
|
146309
145988
|
return identity$8(domain2).unknown(unknown);
|
146310
145989
|
};
|
146311
|
-
domain2 = arguments.length ? Array.from(domain2, number$
|
145990
|
+
domain2 = arguments.length ? Array.from(domain2, number$a) : [0, 1];
|
146312
145991
|
return linearish$1(scale2);
|
146313
145992
|
}
|
146314
145993
|
function nice$2(domain2, interval2) {
|
@@ -146502,17 +146181,17 @@ function pow$5() {
|
|
146502
146181
|
function sqrt$4() {
|
146503
146182
|
return pow$5.apply(null, arguments).exponent(0.5);
|
146504
146183
|
}
|
146505
|
-
function quantile$
|
146184
|
+
function quantile$2() {
|
146506
146185
|
var domain2 = [], range2 = [], thresholds = [], unknown;
|
146507
146186
|
function rescale() {
|
146508
146187
|
var i2 = 0, n2 = Math.max(1, range2.length);
|
146509
146188
|
thresholds = new Array(n2 - 1);
|
146510
146189
|
while (++i2 < n2)
|
146511
|
-
thresholds[i2 - 1] = quantileSorted(domain2, i2 / n2);
|
146190
|
+
thresholds[i2 - 1] = quantileSorted$1(domain2, i2 / n2);
|
146512
146191
|
return scale2;
|
146513
146192
|
}
|
146514
146193
|
function scale2(x2) {
|
146515
|
-
return x2 == null || isNaN(x2 = +x2) ? unknown : range2[bisect$
|
146194
|
+
return x2 == null || isNaN(x2 = +x2) ? unknown : range2[bisect$2(thresholds, x2)];
|
146516
146195
|
}
|
146517
146196
|
scale2.invertExtent = function(y2) {
|
146518
146197
|
var i2 = range2.indexOf(y2);
|
@@ -146528,7 +146207,7 @@ function quantile$1() {
|
|
146528
146207
|
for (let d of _)
|
146529
146208
|
if (d != null && !isNaN(d = +d))
|
146530
146209
|
domain2.push(d);
|
146531
|
-
domain2.sort(ascending$
|
146210
|
+
domain2.sort(ascending$5);
|
146532
146211
|
return rescale();
|
146533
146212
|
};
|
146534
146213
|
scale2.range = function(_) {
|
@@ -146541,14 +146220,14 @@ function quantile$1() {
|
|
146541
146220
|
return thresholds.slice();
|
146542
146221
|
};
|
146543
146222
|
scale2.copy = function() {
|
146544
|
-
return quantile$
|
146223
|
+
return quantile$2().domain(domain2).range(range2).unknown(unknown);
|
146545
146224
|
};
|
146546
146225
|
return initRange$1.apply(scale2, arguments);
|
146547
146226
|
}
|
146548
146227
|
function quantize$3() {
|
146549
146228
|
var x02 = 0, x12 = 1, n2 = 1, domain2 = [0.5], range2 = [0, 1], unknown;
|
146550
146229
|
function scale2(x2) {
|
146551
|
-
return x2 != null && x2 <= x2 ? range2[bisect$
|
146230
|
+
return x2 != null && x2 <= x2 ? range2[bisect$2(domain2, x2, 0, n2)] : unknown;
|
146552
146231
|
}
|
146553
146232
|
function rescale() {
|
146554
146233
|
var i2 = -1;
|
@@ -146581,7 +146260,7 @@ function quantize$3() {
|
|
146581
146260
|
function threshold$1() {
|
146582
146261
|
var domain2 = [0.5], range2 = [0, 1], unknown, n2 = 1;
|
146583
146262
|
function scale2(x2) {
|
146584
|
-
return x2 != null && x2 <= x2 ? range2[bisect$
|
146263
|
+
return x2 != null && x2 <= x2 ? range2[bisect$2(domain2, x2, 0, n2)] : unknown;
|
146585
146264
|
}
|
146586
146265
|
scale2.domain = function(_) {
|
146587
146266
|
return arguments.length ? (domain2 = Array.from(_), n2 = Math.min(domain2.length, range2.length - 1), scale2) : domain2.slice();
|
@@ -146915,11 +146594,11 @@ function ticker$1(year2, month2, week2, day2, hour2, minute2) {
|
|
146915
146594
|
}
|
146916
146595
|
function tickInterval(start, stop3, count2) {
|
146917
146596
|
const target2 = Math.abs(stop3 - start) / count2;
|
146918
|
-
const i2 = bisector$
|
146597
|
+
const i2 = bisector$2(([, , step2]) => step2).right(tickIntervals, target2);
|
146919
146598
|
if (i2 === tickIntervals.length)
|
146920
|
-
return year2.every(tickStep(start / durationYear$2, stop3 / durationYear$2, count2));
|
146599
|
+
return year2.every(tickStep$1(start / durationYear$2, stop3 / durationYear$2, count2));
|
146921
146600
|
if (i2 === 0)
|
146922
|
-
return utcMillisecond.every(Math.max(tickStep(start, stop3, count2), 1));
|
146601
|
+
return utcMillisecond.every(Math.max(tickStep$1(start, stop3, count2), 1));
|
146923
146602
|
const [t4, step] = tickIntervals[target2 / tickIntervals[i2 - 1][2] < tickIntervals[i2][2] / target2 ? i2 - 1 : i2];
|
146924
146603
|
return t4.every(step);
|
146925
146604
|
}
|
@@ -147504,7 +147183,7 @@ function defaultLocale$3(definition2) {
|
|
147504
147183
|
function date$3(t4) {
|
147505
147184
|
return new Date(t4);
|
147506
147185
|
}
|
147507
|
-
function number$
|
147186
|
+
function number$9(t4) {
|
147508
147187
|
return t4 instanceof Date ? +t4 : +/* @__PURE__ */ new Date(+t4);
|
147509
147188
|
}
|
147510
147189
|
function calendar$1(ticks2, tickInterval, year2, month2, week2, day2, hour2, minute2, second2, format2) {
|
@@ -147517,7 +147196,7 @@ function calendar$1(ticks2, tickInterval, year2, month2, week2, day2, hour2, min
|
|
147517
147196
|
return new Date(invert2(y2));
|
147518
147197
|
};
|
147519
147198
|
scale2.domain = function(_) {
|
147520
|
-
return arguments.length ? domain2(Array.from(_, number$
|
147199
|
+
return arguments.length ? domain2(Array.from(_, number$9)) : domain2().map(date$3);
|
147521
147200
|
};
|
147522
147201
|
scale2.ticks = function(interval2) {
|
147523
147202
|
var d = domain2();
|
@@ -147786,7 +147465,7 @@ function field$1(field2, name2, opt) {
|
|
147786
147465
|
}
|
147787
147466
|
const id = field$1("id");
|
147788
147467
|
const identity$7 = accessor((_) => _, [], "identity");
|
147789
|
-
const zero$
|
147468
|
+
const zero$5 = accessor(() => 0, [], "zero");
|
147790
147469
|
const one$3 = accessor(() => 1, [], "one");
|
147791
147470
|
const truthy = accessor(() => true, [], "true");
|
147792
147471
|
const falsy = accessor(() => false, [], "false");
|
@@ -147964,10 +147643,10 @@ function compare$9(fields, orders, opt) {
|
|
147964
147643
|
});
|
147965
147644
|
return get3.length === 0 ? null : accessor(gen(get3, ord), Object.keys(fmap));
|
147966
147645
|
}
|
147967
|
-
const ascending$
|
147646
|
+
const ascending$4 = (u2, v) => (u2 < v || u2 == null) && v != null ? -1 : (u2 > v || v == null) && u2 != null ? 1 : (v = v instanceof Date ? +v : v, u2 = u2 instanceof Date ? +u2 : u2) !== u2 && v === v ? -1 : v !== v && u2 === u2 ? 1 : 0;
|
147968
147647
|
const comparator$1 = (fields, orders) => fields.length === 1 ? compare1(fields[0], orders[0]) : compareN(fields, orders, fields.length);
|
147969
147648
|
const compare1 = (field2, order) => function(a2, b2) {
|
147970
|
-
return ascending$
|
147649
|
+
return ascending$4(field2(a2), field2(b2)) * order;
|
147971
147650
|
};
|
147972
147651
|
const compareN = (fields, orders, n2) => {
|
147973
147652
|
orders.push(0);
|
@@ -147975,7 +147654,7 @@ const compareN = (fields, orders, n2) => {
|
|
147975
147654
|
let f2, c2 = 0, i2 = -1;
|
147976
147655
|
while (c2 === 0 && ++i2 < n2) {
|
147977
147656
|
f2 = fields[i2];
|
147978
|
-
c2 = ascending$
|
147657
|
+
c2 = ascending$4(f2(a2), f2(b2));
|
147979
147658
|
}
|
147980
147659
|
return c2 * orders[i2];
|
147981
147660
|
};
|
@@ -148995,7 +148674,7 @@ function object$2(a2, b2) {
|
|
148995
148674
|
};
|
148996
148675
|
}
|
148997
148676
|
var reA$1 = /[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g, reB$1 = new RegExp(reA$1.source, "g");
|
148998
|
-
function zero$
|
148677
|
+
function zero$4(b2) {
|
148999
148678
|
return function() {
|
149000
148679
|
return b2;
|
149001
148680
|
};
|
@@ -149034,7 +148713,7 @@ function string$1(a2, b2) {
|
|
149034
148713
|
else
|
149035
148714
|
s2[++i2] = bs;
|
149036
148715
|
}
|
149037
|
-
return s2.length < 2 ? q[0] ? one$2(q[0].x) : zero$
|
148716
|
+
return s2.length < 2 ? q[0] ? one$2(q[0].x) : zero$4(b2) : (b2 = q.length, function(t4) {
|
149038
148717
|
for (var i22 = 0, o2; i22 < b2; ++i22)
|
149039
148718
|
s2[(o2 = q[i22]).i] = o2.x(t4);
|
149040
148719
|
return s2.join("");
|
@@ -149065,7 +148744,7 @@ function constants$1(x2) {
|
|
149065
148744
|
return x2;
|
149066
148745
|
};
|
149067
148746
|
}
|
149068
|
-
function number$
|
148747
|
+
function number$8(x2) {
|
149069
148748
|
return +x2;
|
149070
148749
|
}
|
149071
148750
|
var unit = [0, 1];
|
@@ -149130,7 +148809,7 @@ function transformer$3() {
|
|
149130
148809
|
return clamp2(untransform((input || (input = piecewise2(range2, domain2.map(transform2), interpolateNumber)))(y2)));
|
149131
148810
|
};
|
149132
148811
|
scale2.domain = function(_) {
|
149133
|
-
return arguments.length ? (domain2 = Array.from(_, number$
|
148812
|
+
return arguments.length ? (domain2 = Array.from(_, number$8), rescale()) : domain2.slice();
|
149134
148813
|
};
|
149135
148814
|
scale2.range = function(_) {
|
149136
148815
|
return arguments.length ? (range2 = Array.from(_), rescale()) : range2.slice();
|
@@ -149436,7 +149115,7 @@ function linearish(scale2) {
|
|
149436
149115
|
var domain2 = scale2.domain;
|
149437
149116
|
scale2.ticks = function(count2) {
|
149438
149117
|
var d = domain2();
|
149439
|
-
return ticks
|
149118
|
+
return ticks(d[0], d[d.length - 1], count2 == null ? 10 : count2);
|
149440
149119
|
};
|
149441
149120
|
scale2.tickFormat = function(count2, specifier) {
|
149442
149121
|
var d = domain2();
|
@@ -149458,7 +149137,7 @@ function linearish(scale2) {
|
|
149458
149137
|
step = i0, i0 = i1, i1 = step;
|
149459
149138
|
}
|
149460
149139
|
while (maxIter-- > 0) {
|
149461
|
-
step = tickIncrement
|
149140
|
+
step = tickIncrement(start, stop3, count2);
|
149462
149141
|
if (step === prestep) {
|
149463
149142
|
d[i0] = start;
|
149464
149143
|
d[i1] = stop3;
|
@@ -149493,7 +149172,7 @@ function identity$4(domain2) {
|
|
149493
149172
|
}
|
149494
149173
|
scale2.invert = scale2;
|
149495
149174
|
scale2.domain = scale2.range = function(_) {
|
149496
|
-
return arguments.length ? (domain2 = Array.from(_, number$
|
149175
|
+
return arguments.length ? (domain2 = Array.from(_, number$8), scale2) : domain2.slice();
|
149497
149176
|
};
|
149498
149177
|
scale2.unknown = function(_) {
|
149499
149178
|
return arguments.length ? (unknown = _, scale2) : unknown;
|
@@ -149501,7 +149180,7 @@ function identity$4(domain2) {
|
|
149501
149180
|
scale2.copy = function() {
|
149502
149181
|
return identity$4(domain2).unknown(unknown);
|
149503
149182
|
};
|
149504
|
-
domain2 = arguments.length ? Array.from(domain2, number$
|
149183
|
+
domain2 = arguments.length ? Array.from(domain2, number$8) : [0, 1];
|
149505
149184
|
return linearish(scale2);
|
149506
149185
|
}
|
149507
149186
|
function nice$1(domain2, interval2) {
|
@@ -149593,9 +149272,9 @@ function loggish(transform2) {
|
|
149593
149272
|
}
|
149594
149273
|
}
|
149595
149274
|
if (z2.length * 2 < n2)
|
149596
|
-
z2 = ticks
|
149275
|
+
z2 = ticks(u2, v, n2);
|
149597
149276
|
} else {
|
149598
|
-
z2 = ticks
|
149277
|
+
z2 = ticks(i2, j, Math.min(j - i2, n2)).map(pows);
|
149599
149278
|
}
|
149600
149279
|
return r3 ? z2.reverse() : z2;
|
149601
149280
|
};
|
@@ -149692,7 +149371,7 @@ function pow$3() {
|
|
149692
149371
|
function sqrt$3() {
|
149693
149372
|
return pow$3.apply(null, arguments).exponent(0.5);
|
149694
149373
|
}
|
149695
|
-
function quantile() {
|
149374
|
+
function quantile$1() {
|
149696
149375
|
var domain2 = [], range2 = [], thresholds = [], unknown;
|
149697
149376
|
function rescale() {
|
149698
149377
|
var i2 = 0, n2 = Math.max(1, range2.length);
|
@@ -149731,7 +149410,7 @@ function quantile() {
|
|
149731
149410
|
return thresholds.slice();
|
149732
149411
|
};
|
149733
149412
|
scale2.copy = function() {
|
149734
|
-
return quantile().domain(domain2).range(range2).unknown(unknown);
|
149413
|
+
return quantile$1().domain(domain2).range(range2).unknown(unknown);
|
149735
149414
|
};
|
149736
149415
|
return initRange.apply(scale2, arguments);
|
149737
149416
|
}
|
@@ -150876,7 +150555,7 @@ function defaultLocale$1(definition2) {
|
|
150876
150555
|
function date$1(t4) {
|
150877
150556
|
return new Date(t4);
|
150878
150557
|
}
|
150879
|
-
function number$
|
150558
|
+
function number$7(t4) {
|
150880
150559
|
return t4 instanceof Date ? +t4 : +/* @__PURE__ */ new Date(+t4);
|
150881
150560
|
}
|
150882
150561
|
function calendar(ticks2, tickInterval, year2, month2, week2, day2, hour2, minute2, second2, format2) {
|
@@ -150889,7 +150568,7 @@ function calendar(ticks2, tickInterval, year2, month2, week2, day2, hour2, minut
|
|
150889
150568
|
return new Date(invert2(y2));
|
150890
150569
|
};
|
150891
150570
|
scale2.domain = function(_) {
|
150892
|
-
return arguments.length ? domain2(Array.from(_, number$
|
150571
|
+
return arguments.length ? domain2(Array.from(_, number$7)) : domain2().map(date$1);
|
150893
150572
|
};
|
150894
150573
|
scale2.ticks = function(interval2) {
|
150895
150574
|
var d = domain2();
|
@@ -151055,7 +150734,7 @@ function band$1() {
|
|
151055
150734
|
start = Math.round(start);
|
151056
150735
|
bandwidth2 = Math.round(bandwidth2);
|
151057
150736
|
}
|
151058
|
-
var values2 =
|
150737
|
+
var values2 = range$5(n2).map(function(i2) {
|
151059
150738
|
return start + step * i2;
|
151060
150739
|
});
|
151061
150740
|
return ordinalRange(reverse2 ? values2.reverse() : values2);
|
@@ -151174,7 +150853,7 @@ function point$8() {
|
|
151174
150853
|
return pointish$1(band$1().paddingInner(1));
|
151175
150854
|
}
|
151176
150855
|
var map$1 = Array.prototype.map;
|
151177
|
-
function numbers$
|
150856
|
+
function numbers$3(_) {
|
151178
150857
|
return map$1.call(_, function(x2) {
|
151179
150858
|
return +x2;
|
151180
150859
|
});
|
@@ -151187,7 +150866,7 @@ function scaleBinOrdinal$1() {
|
|
151187
150866
|
}
|
151188
150867
|
scale2.domain = function(_) {
|
151189
150868
|
if (arguments.length) {
|
151190
|
-
domain2 = numbers$
|
150869
|
+
domain2 = numbers$3(_);
|
151191
150870
|
return scale2;
|
151192
150871
|
} else {
|
151193
150872
|
return domain2.slice();
|
@@ -151249,7 +150928,7 @@ scale$5(`${Diverging$1}-${Log$1}`, divergingLog, [Continuous$1, Interpolating$1,
|
|
151249
150928
|
scale$5(`${Diverging$1}-${Pow$1}`, divergingPow, [Continuous$1, Interpolating$1]);
|
151250
150929
|
scale$5(`${Diverging$1}-${Sqrt$1}`, divergingSqrt, [Continuous$1, Interpolating$1]);
|
151251
150930
|
scale$5(`${Diverging$1}-${Symlog$1}`, divergingSymlog, [Continuous$1, Interpolating$1]);
|
151252
|
-
scale$5(Quantile$2, quantile, [Discretizing$1, Quantile$2]);
|
150931
|
+
scale$5(Quantile$2, quantile$1, [Discretizing$1, Quantile$2]);
|
151253
150932
|
scale$5(Quantize$1, quantize$2, Discretizing$1);
|
151254
150933
|
scale$5(Threshold$1, threshold, Discretizing$1);
|
151255
150934
|
scale$5(BinOrdinal$1, scaleBinOrdinal$1, [Discrete$2, Discretizing$1]);
|
@@ -151377,7 +151056,7 @@ function date(a2, b2) {
|
|
151377
151056
|
return d.setTime(a2 * (1 - t4) + b2 * t4), d;
|
151378
151057
|
};
|
151379
151058
|
}
|
151380
|
-
function number$
|
151059
|
+
function number$6(a2, b2) {
|
151381
151060
|
return a2 = +a2, b2 = +b2, function(t4) {
|
151382
151061
|
return a2 * (1 - t4) + b2 * t4;
|
151383
151062
|
};
|
@@ -151402,7 +151081,7 @@ function object$1(a2, b2) {
|
|
151402
151081
|
};
|
151403
151082
|
}
|
151404
151083
|
var reA = /[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g, reB = new RegExp(reA.source, "g");
|
151405
|
-
function zero$
|
151084
|
+
function zero$3(b2) {
|
151406
151085
|
return function() {
|
151407
151086
|
return b2;
|
151408
151087
|
};
|
@@ -151430,7 +151109,7 @@ function string(a2, b2) {
|
|
151430
151109
|
s2[++i2] = bm;
|
151431
151110
|
} else {
|
151432
151111
|
s2[++i2] = null;
|
151433
|
-
q.push({ i: i2, x: number$
|
151112
|
+
q.push({ i: i2, x: number$6(am, bm) });
|
151434
151113
|
}
|
151435
151114
|
bi = reB.lastIndex;
|
151436
151115
|
}
|
@@ -151441,7 +151120,7 @@ function string(a2, b2) {
|
|
151441
151120
|
else
|
151442
151121
|
s2[++i2] = bs;
|
151443
151122
|
}
|
151444
|
-
return s2.length < 2 ? q[0] ? one$1(q[0].x) : zero$
|
151123
|
+
return s2.length < 2 ? q[0] ? one$1(q[0].x) : zero$3(b2) : (b2 = q.length, function(t4) {
|
151445
151124
|
for (var i22 = 0, o2; i22 < b2; ++i22)
|
151446
151125
|
s2[(o2 = q[i22]).i] = o2.x(t4);
|
151447
151126
|
return s2.join("");
|
@@ -151449,7 +151128,7 @@ function string(a2, b2) {
|
|
151449
151128
|
}
|
151450
151129
|
function value$3(a2, b2) {
|
151451
151130
|
var t4 = typeof b2, c2;
|
151452
|
-
return b2 == null || t4 === "boolean" ? constant$4(b2) : (t4 === "number" ? number$
|
151131
|
+
return b2 == null || t4 === "boolean" ? constant$4(b2) : (t4 === "number" ? number$6 : t4 === "string" ? (c2 = color$3(b2)) ? (b2 = c2, rgb) : string : b2 instanceof color$3 ? rgb : b2 instanceof Date ? date : isNumberArray(b2) ? numberArray : Array.isArray(b2) ? genericArray : typeof b2.valueOf !== "function" && typeof b2.toString !== "function" || isNaN(b2) ? object$1 : number$6)(a2, b2);
|
151453
151132
|
}
|
151454
151133
|
function discrete$2(range2) {
|
151455
151134
|
var n2 = range2.length;
|
@@ -151527,7 +151206,7 @@ function interpolateTransform(parse2, pxComma, pxParen, degParen) {
|
|
151527
151206
|
function translate2(xa, ya, xb, yb, s2, q) {
|
151528
151207
|
if (xa !== xb || ya !== yb) {
|
151529
151208
|
var i2 = s2.push("translate(", null, pxComma, null, pxParen);
|
151530
|
-
q.push({ i: i2 - 4, x: number$
|
151209
|
+
q.push({ i: i2 - 4, x: number$6(xa, xb) }, { i: i2 - 2, x: number$6(ya, yb) });
|
151531
151210
|
} else if (xb || yb) {
|
151532
151211
|
s2.push("translate(" + xb + pxComma + yb + pxParen);
|
151533
151212
|
}
|
@@ -151538,14 +151217,14 @@ function interpolateTransform(parse2, pxComma, pxParen, degParen) {
|
|
151538
151217
|
b2 += 360;
|
151539
151218
|
else if (b2 - a2 > 180)
|
151540
151219
|
a2 += 360;
|
151541
|
-
q.push({ i: s2.push(pop(s2) + "rotate(", null, degParen) - 2, x: number$
|
151220
|
+
q.push({ i: s2.push(pop(s2) + "rotate(", null, degParen) - 2, x: number$6(a2, b2) });
|
151542
151221
|
} else if (b2) {
|
151543
151222
|
s2.push(pop(s2) + "rotate(" + b2 + degParen);
|
151544
151223
|
}
|
151545
151224
|
}
|
151546
151225
|
function skewX(a2, b2, s2, q) {
|
151547
151226
|
if (a2 !== b2) {
|
151548
|
-
q.push({ i: s2.push(pop(s2) + "skewX(", null, degParen) - 2, x: number$
|
151227
|
+
q.push({ i: s2.push(pop(s2) + "skewX(", null, degParen) - 2, x: number$6(a2, b2) });
|
151549
151228
|
} else if (b2) {
|
151550
151229
|
s2.push(pop(s2) + "skewX(" + b2 + degParen);
|
151551
151230
|
}
|
@@ -151553,7 +151232,7 @@ function interpolateTransform(parse2, pxComma, pxParen, degParen) {
|
|
151553
151232
|
function scale2(xa, ya, xb, yb, s2, q) {
|
151554
151233
|
if (xa !== xb || ya !== yb) {
|
151555
151234
|
var i2 = s2.push(pop(s2) + "scale(", null, ",", null, ")");
|
151556
|
-
q.push({ i: i2 - 4, x: number$
|
151235
|
+
q.push({ i: i2 - 4, x: number$6(xa, xb) }, { i: i2 - 2, x: number$6(ya, yb) });
|
151557
151236
|
} else if (xb !== 1 || yb !== 1) {
|
151558
151237
|
s2.push(pop(s2) + "scale(" + xb + "," + yb + ")");
|
151559
151238
|
}
|
@@ -151700,7 +151379,7 @@ const $ = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
151700
151379
|
interpolateHslLong: hslLong,
|
151701
151380
|
interpolateHue: hue,
|
151702
151381
|
interpolateLab: lab,
|
151703
|
-
interpolateNumber: number$
|
151382
|
+
interpolateNumber: number$6,
|
151704
151383
|
interpolateNumberArray: numberArray,
|
151705
151384
|
interpolateObject: object$1,
|
151706
151385
|
interpolateRgb: rgb,
|
@@ -151827,7 +151506,7 @@ function translateX(x2) {
|
|
151827
151506
|
function translateY(y2) {
|
151828
151507
|
return "translate(0," + y2 + ")";
|
151829
151508
|
}
|
151830
|
-
function number$
|
151509
|
+
function number$5(scale2) {
|
151831
151510
|
return (d) => +scale2(d);
|
151832
151511
|
}
|
151833
151512
|
function center(scale2, offset5) {
|
@@ -151842,7 +151521,7 @@ function entering() {
|
|
151842
151521
|
function axis(orient2, scale2) {
|
151843
151522
|
var tickArguments = [], tickValues2 = null, tickFormat2 = null, tickSizeInner = 6, tickSizeOuter = 6, tickPadding = 3, offset5 = typeof window !== "undefined" && window.devicePixelRatio > 1 ? 0 : 0.5, k = orient2 === top || orient2 === left ? -1 : 1, x2 = orient2 === left || orient2 === right ? "x" : "y", transform2 = orient2 === top || orient2 === bottom ? translateX : translateY;
|
151844
151523
|
function axis2(context2) {
|
151845
|
-
var values2 = tickValues2 == null ? scale2.ticks ? scale2.ticks.apply(scale2, tickArguments) : scale2.domain() : tickValues2, format2 = tickFormat2 == null ? scale2.tickFormat ? scale2.tickFormat.apply(scale2, tickArguments) : identity$2 : tickFormat2, spacing = Math.max(tickSizeInner, 0) + tickPadding, range2 = scale2.range(), range0 = +range2[0] + offset5, range1 = +range2[range2.length - 1] + offset5, position2 = (scale2.bandwidth ? center : number$
|
151524
|
+
var values2 = tickValues2 == null ? scale2.ticks ? scale2.ticks.apply(scale2, tickArguments) : scale2.domain() : tickValues2, format2 = tickFormat2 == null ? scale2.tickFormat ? scale2.tickFormat.apply(scale2, tickArguments) : identity$2 : tickFormat2, spacing = Math.max(tickSizeInner, 0) + tickPadding, range2 = scale2.range(), range0 = +range2[0] + offset5, range1 = +range2[range2.length - 1] + offset5, position2 = (scale2.bandwidth ? center : number$5)(scale2.copy(), offset5), selection = context2.selection ? context2.selection() : context2, path2 = selection.selectAll(".domain").data([null]), tick2 = selection.selectAll(".tick").data(values2, scale2).order(), tickExit = tick2.exit(), tickEnter = tick2.enter().append("g").attr("class", "tick"), line2 = tick2.select("line"), text2 = tick2.select("text");
|
151846
151525
|
path2 = path2.merge(path2.enter().insert("path", ".tick").attr("class", "domain").attr("stroke", "currentColor"));
|
151847
151526
|
tick2 = tick2.merge(tickEnter);
|
151848
151527
|
line2 = line2.merge(tickEnter.append("line").attr("stroke", "currentColor").attr(x2 + "2", k * tickSizeInner));
|
@@ -151918,8 +151597,8 @@ function constant$3(x2) {
|
|
151918
151597
|
const abs$2 = Math.abs;
|
151919
151598
|
const atan2$1 = Math.atan2;
|
151920
151599
|
const cos$2 = Math.cos;
|
151921
|
-
const max$
|
151922
|
-
const min$
|
151600
|
+
const max$2 = Math.max;
|
151601
|
+
const min$2 = Math.min;
|
151923
151602
|
const sin$2 = Math.sin;
|
151924
151603
|
const sqrt$2 = Math.sqrt;
|
151925
151604
|
const epsilon$6 = 1e-12;
|
@@ -152068,7 +151747,7 @@ function intersect$3(x02, y02, x12, y12, x2, y2, x3, y3) {
|
|
152068
151747
|
return [x02 + t4 * x10, y02 + t4 * y10];
|
152069
151748
|
}
|
152070
151749
|
function cornerTangents(x02, y02, x12, y12, r1, rc, cw2) {
|
152071
|
-
var x01 = x02 - x12, y01 = y02 - y12, lo = (cw2 ? rc : -rc) / sqrt$2(x01 * x01 + y01 * y01), ox = lo * y01, oy = -lo * x01, x11 = x02 + ox, y11 = y02 + oy, x10 = x12 + ox, y10 = y12 + oy, x002 = (x11 + x10) / 2, y002 = (y11 + y10) / 2, dx = x10 - x11, dy = y10 - y11, d2 = dx * dx + dy * dy, r3 = r1 - rc, D2 = x11 * y10 - x10 * y11, d = (dy < 0 ? -1 : 1) * sqrt$2(max$
|
151750
|
+
var x01 = x02 - x12, y01 = y02 - y12, lo = (cw2 ? rc : -rc) / sqrt$2(x01 * x01 + y01 * y01), ox = lo * y01, oy = -lo * x01, x11 = x02 + ox, y11 = y02 + oy, x10 = x12 + ox, y10 = y12 + oy, x002 = (x11 + x10) / 2, y002 = (y11 + y10) / 2, dx = x10 - x11, dy = y10 - y11, d2 = dx * dx + dy * dy, r3 = r1 - rc, D2 = x11 * y10 - x10 * y11, d = (dy < 0 ? -1 : 1) * sqrt$2(max$2(0, r3 * r3 * d2 - D2 * D2)), cx0 = (D2 * dy - dx * d) / d2, cy0 = (-D2 * dx - dy * d) / d2, cx1 = (D2 * dy + dx * d) / d2, cy1 = (-D2 * dx + dy * d) / d2, dx0 = cx0 - x002, dy0 = cy0 - y002, dx1 = cx1 - x002, dy1 = cy1 - y002;
|
152072
151751
|
if (dx0 * dx0 + dy0 * dy0 > dx1 * dx1 + dy1 * dy1)
|
152073
151752
|
cx0 = cx1, cy0 = cy1;
|
152074
151753
|
return {
|
@@ -152098,7 +151777,7 @@ function arc$2$1() {
|
|
152098
151777
|
context2.arc(0, 0, r0, a1, a0, cw2);
|
152099
151778
|
}
|
152100
151779
|
} else {
|
152101
|
-
var a01 = a0, a11 = a1, a00 = a0, a10 = a1, da0 = da, da1 = da, ap = padAngle.apply(this, arguments) / 2, rp = ap > epsilon$6 && (padRadius ? +padRadius.apply(this, arguments) : sqrt$2(r0 * r0 + r1 * r1)), rc = min$
|
151780
|
+
var a01 = a0, a11 = a1, a00 = a0, a10 = a1, da0 = da, da1 = da, ap = padAngle.apply(this, arguments) / 2, rp = ap > epsilon$6 && (padRadius ? +padRadius.apply(this, arguments) : sqrt$2(r0 * r0 + r1 * r1)), rc = min$2(abs$2(r1 - r0) / 2, +cornerRadius.apply(this, arguments)), rc0 = rc, rc1 = rc, t02, t12;
|
152102
151781
|
if (rp > epsilon$6) {
|
152103
151782
|
var p02 = asin$2(rp / r0 * sin$2(ap)), p1 = asin$2(rp / r1 * sin$2(ap));
|
152104
151783
|
if ((da0 -= p02 * 2) > epsilon$6)
|
@@ -152116,8 +151795,8 @@ function arc$2$1() {
|
|
152116
151795
|
if (da < pi$3) {
|
152117
151796
|
if (oc = intersect$3(x01, y01, x002, y002, x11, y11, x10, y10)) {
|
152118
151797
|
var ax = x01 - oc[0], ay = y01 - oc[1], bx = x11 - oc[0], by = y11 - oc[1], kc = 1 / sin$2(acos$1((ax * bx + ay * by) / (sqrt$2(ax * ax + ay * ay) * sqrt$2(bx * bx + by * by))) / 2), lc = sqrt$2(oc[0] * oc[0] + oc[1] * oc[1]);
|
152119
|
-
rc0 = min$
|
152120
|
-
rc1 = min$
|
151798
|
+
rc0 = min$2(rc, (r0 - lc) / (kc - 1));
|
151799
|
+
rc1 = min$2(rc, (r1 - lc) / (kc + 1));
|
152121
151800
|
} else {
|
152122
151801
|
rc0 = rc1 = 0;
|
152123
151802
|
}
|
@@ -153485,7 +153164,7 @@ function selection_order() {
|
|
153485
153164
|
}
|
153486
153165
|
function selection_sort(compare2) {
|
153487
153166
|
if (!compare2)
|
153488
|
-
compare2 = ascending$
|
153167
|
+
compare2 = ascending$3;
|
153489
153168
|
function compareNode(a2, b2) {
|
153490
153169
|
return a2 && b2 ? compare2(a2.__data__, b2.__data__) : !a2 - !b2;
|
153491
153170
|
}
|
@@ -153499,7 +153178,7 @@ function selection_sort(compare2) {
|
|
153499
153178
|
}
|
153500
153179
|
return new Selection(sortgroups, this._parents).order();
|
153501
153180
|
}
|
153502
|
-
function ascending$
|
153181
|
+
function ascending$3(a2, b2) {
|
153503
153182
|
return a2 < b2 ? -1 : a2 > b2 ? 1 : a2 >= b2 ? 0 : NaN;
|
153504
153183
|
}
|
153505
153184
|
function selection_call() {
|
@@ -155026,6 +154705,291 @@ function extractArcs(topology, object2, filter2) {
|
|
155026
154705
|
});
|
155027
154706
|
return arcs;
|
155028
154707
|
}
|
154708
|
+
function ascending$2(a2, b2) {
|
154709
|
+
return a2 == null || b2 == null ? NaN : a2 < b2 ? -1 : a2 > b2 ? 1 : a2 >= b2 ? 0 : NaN;
|
154710
|
+
}
|
154711
|
+
function descending$1(a2, b2) {
|
154712
|
+
return a2 == null || b2 == null ? NaN : b2 < a2 ? -1 : b2 > a2 ? 1 : b2 >= a2 ? 0 : NaN;
|
154713
|
+
}
|
154714
|
+
function bisector$1(f2) {
|
154715
|
+
let compare12, compare2, delta;
|
154716
|
+
if (f2.length !== 2) {
|
154717
|
+
compare12 = ascending$2;
|
154718
|
+
compare2 = (d, x2) => ascending$2(f2(d), x2);
|
154719
|
+
delta = (d, x2) => f2(d) - x2;
|
154720
|
+
} else {
|
154721
|
+
compare12 = f2 === ascending$2 || f2 === descending$1 ? f2 : zero$2;
|
154722
|
+
compare2 = f2;
|
154723
|
+
delta = f2;
|
154724
|
+
}
|
154725
|
+
function left2(a2, x2, lo = 0, hi = a2.length) {
|
154726
|
+
if (lo < hi) {
|
154727
|
+
if (compare12(x2, x2) !== 0)
|
154728
|
+
return hi;
|
154729
|
+
do {
|
154730
|
+
const mid = lo + hi >>> 1;
|
154731
|
+
if (compare2(a2[mid], x2) < 0)
|
154732
|
+
lo = mid + 1;
|
154733
|
+
else
|
154734
|
+
hi = mid;
|
154735
|
+
} while (lo < hi);
|
154736
|
+
}
|
154737
|
+
return lo;
|
154738
|
+
}
|
154739
|
+
function right2(a2, x2, lo = 0, hi = a2.length) {
|
154740
|
+
if (lo < hi) {
|
154741
|
+
if (compare12(x2, x2) !== 0)
|
154742
|
+
return hi;
|
154743
|
+
do {
|
154744
|
+
const mid = lo + hi >>> 1;
|
154745
|
+
if (compare2(a2[mid], x2) <= 0)
|
154746
|
+
lo = mid + 1;
|
154747
|
+
else
|
154748
|
+
hi = mid;
|
154749
|
+
} while (lo < hi);
|
154750
|
+
}
|
154751
|
+
return lo;
|
154752
|
+
}
|
154753
|
+
function center2(a2, x2, lo = 0, hi = a2.length) {
|
154754
|
+
const i2 = left2(a2, x2, lo, hi - 1);
|
154755
|
+
return i2 > lo && delta(a2[i2 - 1], x2) > -delta(a2[i2], x2) ? i2 - 1 : i2;
|
154756
|
+
}
|
154757
|
+
return { left: left2, center: center2, right: right2 };
|
154758
|
+
}
|
154759
|
+
function zero$2() {
|
154760
|
+
return 0;
|
154761
|
+
}
|
154762
|
+
function number$4(x2) {
|
154763
|
+
return x2 === null ? NaN : +x2;
|
154764
|
+
}
|
154765
|
+
function* numbers$2(values2, valueof) {
|
154766
|
+
if (valueof === void 0) {
|
154767
|
+
for (let value2 of values2) {
|
154768
|
+
if (value2 != null && (value2 = +value2) >= value2) {
|
154769
|
+
yield value2;
|
154770
|
+
}
|
154771
|
+
}
|
154772
|
+
} else {
|
154773
|
+
let index2 = -1;
|
154774
|
+
for (let value2 of values2) {
|
154775
|
+
if ((value2 = valueof(value2, ++index2, values2)) != null && (value2 = +value2) >= value2) {
|
154776
|
+
yield value2;
|
154777
|
+
}
|
154778
|
+
}
|
154779
|
+
}
|
154780
|
+
}
|
154781
|
+
const ascendingBisect = bisector$1(ascending$2);
|
154782
|
+
const bisectRight$1 = ascendingBisect.right;
|
154783
|
+
const bisectLeft$1 = ascendingBisect.left;
|
154784
|
+
bisector$1(number$4).center;
|
154785
|
+
const bisect$1 = bisectRight$1;
|
154786
|
+
function variance(values2, valueof) {
|
154787
|
+
let count2 = 0;
|
154788
|
+
let delta;
|
154789
|
+
let mean2 = 0;
|
154790
|
+
let sum2 = 0;
|
154791
|
+
if (valueof === void 0) {
|
154792
|
+
for (let value2 of values2) {
|
154793
|
+
if (value2 != null && (value2 = +value2) >= value2) {
|
154794
|
+
delta = value2 - mean2;
|
154795
|
+
mean2 += delta / ++count2;
|
154796
|
+
sum2 += delta * (value2 - mean2);
|
154797
|
+
}
|
154798
|
+
}
|
154799
|
+
} else {
|
154800
|
+
let index2 = -1;
|
154801
|
+
for (let value2 of values2) {
|
154802
|
+
if ((value2 = valueof(value2, ++index2, values2)) != null && (value2 = +value2) >= value2) {
|
154803
|
+
delta = value2 - mean2;
|
154804
|
+
mean2 += delta / ++count2;
|
154805
|
+
sum2 += delta * (value2 - mean2);
|
154806
|
+
}
|
154807
|
+
}
|
154808
|
+
}
|
154809
|
+
if (count2 > 1)
|
154810
|
+
return sum2 / (count2 - 1);
|
154811
|
+
}
|
154812
|
+
function deviation(values2, valueof) {
|
154813
|
+
const v = variance(values2, valueof);
|
154814
|
+
return v ? Math.sqrt(v) : v;
|
154815
|
+
}
|
154816
|
+
function permute(source2, keys3) {
|
154817
|
+
return Array.from(keys3, (key2) => source2[key2]);
|
154818
|
+
}
|
154819
|
+
function compareDefined(compare2 = ascending$2) {
|
154820
|
+
if (compare2 === ascending$2)
|
154821
|
+
return ascendingDefined;
|
154822
|
+
if (typeof compare2 !== "function")
|
154823
|
+
throw new TypeError("compare is not a function");
|
154824
|
+
return (a2, b2) => {
|
154825
|
+
const x2 = compare2(a2, b2);
|
154826
|
+
if (x2 || x2 === 0)
|
154827
|
+
return x2;
|
154828
|
+
return (compare2(b2, b2) === 0) - (compare2(a2, a2) === 0);
|
154829
|
+
};
|
154830
|
+
}
|
154831
|
+
function ascendingDefined(a2, b2) {
|
154832
|
+
return (a2 == null || !(a2 >= a2)) - (b2 == null || !(b2 >= b2)) || (a2 < b2 ? -1 : a2 > b2 ? 1 : 0);
|
154833
|
+
}
|
154834
|
+
var e10 = Math.sqrt(50), e5 = Math.sqrt(10), e2 = Math.sqrt(2);
|
154835
|
+
function tickStep(start, stop3, count2) {
|
154836
|
+
var step0 = Math.abs(stop3 - start) / Math.max(0, count2), step1 = Math.pow(10, Math.floor(Math.log(step0) / Math.LN10)), error2 = step0 / step1;
|
154837
|
+
if (error2 >= e10)
|
154838
|
+
step1 *= 10;
|
154839
|
+
else if (error2 >= e5)
|
154840
|
+
step1 *= 5;
|
154841
|
+
else if (error2 >= e2)
|
154842
|
+
step1 *= 2;
|
154843
|
+
return stop3 < start ? -step1 : step1;
|
154844
|
+
}
|
154845
|
+
function max$1(values2, valueof) {
|
154846
|
+
let max2;
|
154847
|
+
if (valueof === void 0) {
|
154848
|
+
for (const value2 of values2) {
|
154849
|
+
if (value2 != null && (max2 < value2 || max2 === void 0 && value2 >= value2)) {
|
154850
|
+
max2 = value2;
|
154851
|
+
}
|
154852
|
+
}
|
154853
|
+
} else {
|
154854
|
+
let index2 = -1;
|
154855
|
+
for (let value2 of values2) {
|
154856
|
+
if ((value2 = valueof(value2, ++index2, values2)) != null && (max2 < value2 || max2 === void 0 && value2 >= value2)) {
|
154857
|
+
max2 = value2;
|
154858
|
+
}
|
154859
|
+
}
|
154860
|
+
}
|
154861
|
+
return max2;
|
154862
|
+
}
|
154863
|
+
function min$1(values2, valueof) {
|
154864
|
+
let min2;
|
154865
|
+
if (valueof === void 0) {
|
154866
|
+
for (const value2 of values2) {
|
154867
|
+
if (value2 != null && (min2 > value2 || min2 === void 0 && value2 >= value2)) {
|
154868
|
+
min2 = value2;
|
154869
|
+
}
|
154870
|
+
}
|
154871
|
+
} else {
|
154872
|
+
let index2 = -1;
|
154873
|
+
for (let value2 of values2) {
|
154874
|
+
if ((value2 = valueof(value2, ++index2, values2)) != null && (min2 > value2 || min2 === void 0 && value2 >= value2)) {
|
154875
|
+
min2 = value2;
|
154876
|
+
}
|
154877
|
+
}
|
154878
|
+
}
|
154879
|
+
return min2;
|
154880
|
+
}
|
154881
|
+
function quickselect(array2, k, left2 = 0, right2 = array2.length - 1, compare2) {
|
154882
|
+
compare2 = compare2 === void 0 ? ascendingDefined : compareDefined(compare2);
|
154883
|
+
while (right2 > left2) {
|
154884
|
+
if (right2 - left2 > 600) {
|
154885
|
+
const n2 = right2 - left2 + 1;
|
154886
|
+
const m2 = k - left2 + 1;
|
154887
|
+
const z2 = Math.log(n2);
|
154888
|
+
const s2 = 0.5 * Math.exp(2 * z2 / 3);
|
154889
|
+
const sd = 0.5 * Math.sqrt(z2 * s2 * (n2 - s2) / n2) * (m2 - n2 / 2 < 0 ? -1 : 1);
|
154890
|
+
const newLeft = Math.max(left2, Math.floor(k - m2 * s2 / n2 + sd));
|
154891
|
+
const newRight = Math.min(right2, Math.floor(k + (n2 - m2) * s2 / n2 + sd));
|
154892
|
+
quickselect(array2, k, newLeft, newRight, compare2);
|
154893
|
+
}
|
154894
|
+
const t4 = array2[k];
|
154895
|
+
let i2 = left2;
|
154896
|
+
let j = right2;
|
154897
|
+
swap$1(array2, left2, k);
|
154898
|
+
if (compare2(array2[right2], t4) > 0)
|
154899
|
+
swap$1(array2, left2, right2);
|
154900
|
+
while (i2 < j) {
|
154901
|
+
swap$1(array2, i2, j), ++i2, --j;
|
154902
|
+
while (compare2(array2[i2], t4) < 0)
|
154903
|
+
++i2;
|
154904
|
+
while (compare2(array2[j], t4) > 0)
|
154905
|
+
--j;
|
154906
|
+
}
|
154907
|
+
if (compare2(array2[left2], t4) === 0)
|
154908
|
+
swap$1(array2, left2, j);
|
154909
|
+
else
|
154910
|
+
++j, swap$1(array2, j, right2);
|
154911
|
+
if (j <= k)
|
154912
|
+
left2 = j + 1;
|
154913
|
+
if (k <= j)
|
154914
|
+
right2 = j - 1;
|
154915
|
+
}
|
154916
|
+
return array2;
|
154917
|
+
}
|
154918
|
+
function swap$1(array2, i2, j) {
|
154919
|
+
const t4 = array2[i2];
|
154920
|
+
array2[i2] = array2[j];
|
154921
|
+
array2[j] = t4;
|
154922
|
+
}
|
154923
|
+
function quantile(values2, p, valueof) {
|
154924
|
+
values2 = Float64Array.from(numbers$2(values2, valueof));
|
154925
|
+
if (!(n2 = values2.length))
|
154926
|
+
return;
|
154927
|
+
if ((p = +p) <= 0 || n2 < 2)
|
154928
|
+
return min$1(values2);
|
154929
|
+
if (p >= 1)
|
154930
|
+
return max$1(values2);
|
154931
|
+
var n2, i2 = (n2 - 1) * p, i0 = Math.floor(i2), value0 = max$1(quickselect(values2, i0).subarray(0, i0 + 1)), value1 = min$1(values2.subarray(i0 + 1));
|
154932
|
+
return value0 + (value1 - value0) * (i2 - i0);
|
154933
|
+
}
|
154934
|
+
function quantileSorted(values2, p, valueof = number$4) {
|
154935
|
+
if (!(n2 = values2.length))
|
154936
|
+
return;
|
154937
|
+
if ((p = +p) <= 0 || n2 < 2)
|
154938
|
+
return +valueof(values2[0], 0, values2);
|
154939
|
+
if (p >= 1)
|
154940
|
+
return +valueof(values2[n2 - 1], n2 - 1, values2);
|
154941
|
+
var n2, i2 = (n2 - 1) * p, i0 = Math.floor(i2), value0 = +valueof(values2[i0], i0, values2), value1 = +valueof(values2[i0 + 1], i0 + 1, values2);
|
154942
|
+
return value0 + (value1 - value0) * (i2 - i0);
|
154943
|
+
}
|
154944
|
+
function mean(values2, valueof) {
|
154945
|
+
let count2 = 0;
|
154946
|
+
let sum2 = 0;
|
154947
|
+
if (valueof === void 0) {
|
154948
|
+
for (let value2 of values2) {
|
154949
|
+
if (value2 != null && (value2 = +value2) >= value2) {
|
154950
|
+
++count2, sum2 += value2;
|
154951
|
+
}
|
154952
|
+
}
|
154953
|
+
} else {
|
154954
|
+
let index2 = -1;
|
154955
|
+
for (let value2 of values2) {
|
154956
|
+
if ((value2 = valueof(value2, ++index2, values2)) != null && (value2 = +value2) >= value2) {
|
154957
|
+
++count2, sum2 += value2;
|
154958
|
+
}
|
154959
|
+
}
|
154960
|
+
}
|
154961
|
+
if (count2)
|
154962
|
+
return sum2 / count2;
|
154963
|
+
}
|
154964
|
+
function median(values2, valueof) {
|
154965
|
+
return quantile(values2, 0.5, valueof);
|
154966
|
+
}
|
154967
|
+
function range$4(start, stop3, step) {
|
154968
|
+
start = +start, stop3 = +stop3, step = (n2 = arguments.length) < 2 ? (stop3 = start, start = 0, 1) : n2 < 3 ? 1 : +step;
|
154969
|
+
var i2 = -1, n2 = Math.max(0, Math.ceil((stop3 - start) / step)) | 0, range2 = new Array(n2);
|
154970
|
+
while (++i2 < n2) {
|
154971
|
+
range2[i2] = start + i2 * step;
|
154972
|
+
}
|
154973
|
+
return range2;
|
154974
|
+
}
|
154975
|
+
function sum$1(values2, valueof) {
|
154976
|
+
let sum2 = 0;
|
154977
|
+
if (valueof === void 0) {
|
154978
|
+
for (let value2 of values2) {
|
154979
|
+
if (value2 = +value2) {
|
154980
|
+
sum2 += value2;
|
154981
|
+
}
|
154982
|
+
}
|
154983
|
+
} else {
|
154984
|
+
let index2 = -1;
|
154985
|
+
for (let value2 of values2) {
|
154986
|
+
if (value2 = +valueof(value2, ++index2, values2)) {
|
154987
|
+
sum2 += value2;
|
154988
|
+
}
|
154989
|
+
}
|
154990
|
+
}
|
154991
|
+
return sum2;
|
154992
|
+
}
|
155029
154993
|
const YEAR = "year";
|
155030
154994
|
const QUARTER = "quarter";
|
155031
154995
|
const MONTH = "month";
|
@@ -155150,7 +155114,7 @@ function floor(units2, step, get3, inv, newDate2) {
|
|
155150
155114
|
key2 = key2 || unit2;
|
155151
155115
|
return getUnit(get3[key2], inv[key2], unit2 === b2 && s2, p);
|
155152
155116
|
};
|
155153
|
-
const t4 = /* @__PURE__ */ new Date(), u2 = toSet(units2), y2 = u2[YEAR] ? _(YEAR) : constant$6(2012), m2 = u2[MONTH] ? _(MONTH) : u2[QUARTER] ? _(QUARTER) : zero$
|
155117
|
+
const t4 = /* @__PURE__ */ new Date(), u2 = toSet(units2), y2 = u2[YEAR] ? _(YEAR) : constant$6(2012), m2 = u2[MONTH] ? _(MONTH) : u2[QUARTER] ? _(QUARTER) : zero$5, d = u2[WEEK] && u2[DAY] ? _(DAY, 1, WEEK + DAY) : u2[WEEK] ? _(WEEK, 1) : u2[DAY] ? _(DAY, 1) : u2[DATE] ? _(DATE, 1) : u2[DAYOFYEAR] ? _(DAYOFYEAR, 1) : one$3, H = u2[HOURS] ? _(HOURS) : zero$5, M2 = u2[MINUTES] ? _(MINUTES) : zero$5, S = u2[SECONDS] ? _(SECONDS) : zero$5, L = u2[MILLISECONDS] ? _(MILLISECONDS) : zero$5;
|
155154
155118
|
return function(v) {
|
155155
155119
|
t4.setTime(+v);
|
155156
155120
|
const year2 = y2(t4);
|
@@ -157267,7 +157231,7 @@ function* numbers$1(values2, valueof) {
|
|
157267
157231
|
}
|
157268
157232
|
function quantiles(array2, p, f2) {
|
157269
157233
|
const values2 = Float64Array.from(numbers$1(array2, f2));
|
157270
|
-
values2.sort(ascending$
|
157234
|
+
values2.sort(ascending$2);
|
157271
157235
|
return p.map((_) => quantileSorted(values2, _));
|
157272
157236
|
}
|
157273
157237
|
function quartiles(array2, f2) {
|
@@ -157329,8 +157293,8 @@ function bootstrapCI(array2, samples, alpha2, f2) {
|
|
157329
157293
|
}
|
157330
157294
|
mu[j] = a2 / n2;
|
157331
157295
|
}
|
157332
|
-
mu.sort(ascending$
|
157333
|
-
return [quantile
|
157296
|
+
mu.sort(ascending$2);
|
157297
|
+
return [quantile(mu, alpha2 / 2), quantile(mu, 1 - alpha2 / 2)];
|
157334
157298
|
}
|
157335
157299
|
function dotbin(array2, step, smooth, f2) {
|
157336
157300
|
f2 = f2 || ((_) => _);
|
@@ -159753,8 +159717,8 @@ const Methods$1 = {
|
|
159753
159717
|
value: "value",
|
159754
159718
|
median,
|
159755
159719
|
mean,
|
159756
|
-
min: min$
|
159757
|
-
max: max$
|
159720
|
+
min: min$1,
|
159721
|
+
max: max$1
|
159758
159722
|
};
|
159759
159723
|
const Empty$1 = [];
|
159760
159724
|
function Impute(params2) {
|
@@ -160237,7 +160201,7 @@ function pivotKeys(key2, limit, pulse2) {
|
|
160237
160201
|
list.push(k);
|
160238
160202
|
}
|
160239
160203
|
});
|
160240
|
-
list.sort(ascending$
|
160204
|
+
list.sort(ascending$4);
|
160241
160205
|
return limit ? list.slice(0, limit) : list;
|
160242
160206
|
}
|
160243
160207
|
function PreFacet$1(params2) {
|
@@ -160693,7 +160657,7 @@ inherits(Values$1, Transform2, {
|
|
160693
160657
|
function WindowOp(op, field2, param2, as) {
|
160694
160658
|
const fn = WindowOps[op](field2, param2);
|
160695
160659
|
return {
|
160696
|
-
init: fn.init || zero$
|
160660
|
+
init: fn.init || zero$5,
|
160697
160661
|
update: function(w2, t4) {
|
160698
160662
|
t4[as] = fn.next(w2);
|
160699
160663
|
}
|
@@ -161377,7 +161341,7 @@ scale$4("".concat(Diverging, "-").concat(Log2), divergingLog$1, [Continuous, Int
|
|
161377
161341
|
scale$4("".concat(Diverging, "-").concat(Pow), divergingPow$1, [Continuous, Interpolating]);
|
161378
161342
|
scale$4("".concat(Diverging, "-").concat(Sqrt), divergingSqrt$1, [Continuous, Interpolating]);
|
161379
161343
|
scale$4("".concat(Diverging, "-").concat(Symlog), divergingSymlog$1, [Continuous, Interpolating]);
|
161380
|
-
scale$4(Quantile, quantile$
|
161344
|
+
scale$4(Quantile, quantile$2, [Discretizing, Quantile]);
|
161381
161345
|
scale$4(Quantize, quantize$3, Discretizing);
|
161382
161346
|
scale$4(Threshold, threshold$1, Discretizing);
|
161383
161347
|
scale$4(BinOrdinal, scaleBinOrdinal, [Discrete$1, Discretizing]);
|
@@ -163182,9 +163146,9 @@ function transformItem(item) {
|
|
163182
163146
|
return translate$2(item.x || 0, item.y || 0) + (item.angle ? " " + rotate(item.angle) : "") + (item.scaleX || item.scaleY ? " " + scale$3(item.scaleX || 1, item.scaleY || 1) : "");
|
163183
163147
|
}
|
163184
163148
|
function markItemPath(type2, shape2, isect) {
|
163185
|
-
function attr2(
|
163186
|
-
|
163187
|
-
|
163149
|
+
function attr2(emit2, item) {
|
163150
|
+
emit2("transform", rotateItem(item));
|
163151
|
+
emit2("d", shape2(null, item));
|
163188
163152
|
}
|
163189
163153
|
function bound2(bounds2, item) {
|
163190
163154
|
shape2(boundContext(bounds2, item.angle), item);
|
@@ -163254,10 +163218,10 @@ function pickTrail(a2, p) {
|
|
163254
163218
|
return null;
|
163255
163219
|
}
|
163256
163220
|
function markMultiItemPath(type2, shape2, tip) {
|
163257
|
-
function attr2(
|
163221
|
+
function attr2(emit2, item) {
|
163258
163222
|
var items = item.mark.items;
|
163259
163223
|
if (items.length)
|
163260
|
-
|
163224
|
+
emit2("d", shape2(null, items));
|
163261
163225
|
}
|
163262
163226
|
function bound2(bounds2, mark2) {
|
163263
163227
|
var items = mark2.items;
|
@@ -163315,30 +163279,30 @@ function offset$1(item) {
|
|
163315
163279
|
const sw = value$2(item.strokeWidth, 1);
|
163316
163280
|
return item.strokeOffset != null ? item.strokeOffset : item.stroke && sw > 0.5 && sw < 1.5 ? 0.5 - Math.abs(sw - 1) : 0;
|
163317
163281
|
}
|
163318
|
-
function attr$5(
|
163319
|
-
|
163282
|
+
function attr$5(emit2, item) {
|
163283
|
+
emit2("transform", translateItem(item));
|
163320
163284
|
}
|
163321
|
-
function emitRectangle(
|
163285
|
+
function emitRectangle(emit2, item) {
|
163322
163286
|
const off = offset$1(item);
|
163323
|
-
|
163287
|
+
emit2("d", rectangle(null, item, off, off));
|
163324
163288
|
}
|
163325
|
-
function background$1(
|
163326
|
-
|
163327
|
-
|
163328
|
-
emitRectangle(
|
163289
|
+
function background$1(emit2, item) {
|
163290
|
+
emit2("class", "background");
|
163291
|
+
emit2("aria-hidden", true);
|
163292
|
+
emitRectangle(emit2, item);
|
163329
163293
|
}
|
163330
|
-
function foreground(
|
163331
|
-
|
163332
|
-
|
163294
|
+
function foreground(emit2, item) {
|
163295
|
+
emit2("class", "foreground");
|
163296
|
+
emit2("aria-hidden", true);
|
163333
163297
|
if (item.strokeForeground) {
|
163334
|
-
emitRectangle(
|
163298
|
+
emitRectangle(emit2, item);
|
163335
163299
|
} else {
|
163336
|
-
|
163300
|
+
emit2("d", "");
|
163337
163301
|
}
|
163338
163302
|
}
|
163339
|
-
function content(
|
163303
|
+
function content(emit2, item, renderer) {
|
163340
163304
|
const url = item.clip ? clip$1$1(renderer, item, item) : null;
|
163341
|
-
|
163305
|
+
emit2("clip-path", url);
|
163342
163306
|
}
|
163343
163307
|
function bound$5(bounds2, group2) {
|
163344
163308
|
if (!group2.clip && group2.items) {
|
@@ -163479,13 +163443,13 @@ function imageXOffset(align2, w2) {
|
|
163479
163443
|
function imageYOffset(baseline2, h2) {
|
163480
163444
|
return baseline2 === "middle" ? h2 / 2 : baseline2 === "bottom" ? h2 : 0;
|
163481
163445
|
}
|
163482
|
-
function attr$4(
|
163446
|
+
function attr$4(emit2, item, renderer) {
|
163483
163447
|
const img = getImage(item, renderer), w2 = imageWidth(item, img), h2 = imageHeight(item, img), x2 = (item.x || 0) - imageXOffset(item.align, w2), y2 = (item.y || 0) - imageYOffset(item.baseline, h2), i2 = !img.src && img.toDataURL ? img.toDataURL() : img.src || "";
|
163484
|
-
|
163485
|
-
|
163486
|
-
|
163487
|
-
|
163488
|
-
|
163448
|
+
emit2("href", i2, metadata["xmlns:xlink"], "xlink:href");
|
163449
|
+
emit2("transform", translate$2(x2, y2));
|
163450
|
+
emit2("width", w2);
|
163451
|
+
emit2("height", h2);
|
163452
|
+
emit2("preserveAspectRatio", item.aspect === false ? "none" : "xMidYMid");
|
163489
163453
|
}
|
163490
163454
|
function bound$4(bounds2, item) {
|
163491
163455
|
const img = item.image, w2 = imageWidth(item, img), h2 = imageHeight(item, img), x2 = (item.x || 0) - imageXOffset(item.align, w2), y2 = (item.y || 0) - imageYOffset(item.baseline, h2);
|
@@ -163539,13 +163503,13 @@ var image$1 = {
|
|
163539
163503
|
yOffset: imageYOffset
|
163540
163504
|
};
|
163541
163505
|
var line$2 = markMultiItemPath("line", line$1$1, pickLine);
|
163542
|
-
function attr$3(
|
163506
|
+
function attr$3(emit2, item) {
|
163543
163507
|
var sx = item.scaleX || 1, sy = item.scaleY || 1;
|
163544
163508
|
if (sx !== 1 || sy !== 1) {
|
163545
|
-
|
163509
|
+
emit2("vector-effect", "non-scaling-stroke");
|
163546
163510
|
}
|
163547
|
-
|
163548
|
-
|
163511
|
+
emit2("transform", transformItem(item));
|
163512
|
+
emit2("d", item.path);
|
163549
163513
|
}
|
163550
163514
|
function path$1(context2, item) {
|
163551
163515
|
var path2 = item.path;
|
@@ -163578,8 +163542,8 @@ var path$2 = {
|
|
163578
163542
|
pick: pickPath(path$1),
|
163579
163543
|
isect: intersectPath(path$1)
|
163580
163544
|
};
|
163581
|
-
function attr$2(
|
163582
|
-
|
163545
|
+
function attr$2(emit2, item) {
|
163546
|
+
emit2("d", rectangle(null, item));
|
163583
163547
|
}
|
163584
163548
|
function bound$2(bounds2, item) {
|
163585
163549
|
var x2, y2;
|
@@ -163599,10 +163563,10 @@ var rect$1 = {
|
|
163599
163563
|
pick: pickPath(draw$2),
|
163600
163564
|
isect: intersectRect
|
163601
163565
|
};
|
163602
|
-
function attr$1(
|
163603
|
-
|
163604
|
-
|
163605
|
-
|
163566
|
+
function attr$1(emit2, item) {
|
163567
|
+
emit2("transform", translateItem(item));
|
163568
|
+
emit2("x2", item.x2 != null ? item.x2 - (item.x || 0) : 0);
|
163569
|
+
emit2("y2", item.y2 != null ? item.y2 - (item.y || 0) : 0);
|
163606
163570
|
}
|
163607
163571
|
function bound$1(bounds2, item) {
|
163608
163572
|
var x12, y12;
|
@@ -163764,9 +163728,9 @@ function anchorPoint(item) {
|
|
163764
163728
|
tempBounds$1.y1 = y2;
|
163765
163729
|
return tempBounds$1;
|
163766
163730
|
}
|
163767
|
-
function attr(
|
163731
|
+
function attr(emit2, item) {
|
163768
163732
|
var dx = item.dx || 0, dy = (item.dy || 0) + offset$2(item), p = anchorPoint(item), x2 = p.x1, y2 = p.y1, a2 = item.angle || 0, t4;
|
163769
|
-
|
163733
|
+
emit2("text-anchor", textAlign[item.align] || "start");
|
163770
163734
|
if (a2) {
|
163771
163735
|
t4 = translate$2(x2, y2) + " " + rotate(a2);
|
163772
163736
|
if (dx || dy)
|
@@ -163774,7 +163738,7 @@ function attr(emit3, item) {
|
|
163774
163738
|
} else {
|
163775
163739
|
t4 = translate$2(x2 + dx, y2 + dy);
|
163776
163740
|
}
|
163777
|
-
|
163741
|
+
emit2("transform", t4);
|
163778
163742
|
}
|
163779
163743
|
function bound(bounds2, item, mode) {
|
163780
163744
|
var h2 = textMetrics.height(item), a2 = item.align, p = anchorPoint(item), x2 = p.x1, y2 = p.y1, dx = item.dx || 0, dy = (item.dy || 0) + offset$2(item) - Math.round(0.8 * h2), tl2 = textLines(item), w2;
|
@@ -164801,18 +164765,18 @@ const AriaEncode = {
|
|
164801
164765
|
ariaRoleDescription: ARIA_ROLEDESCRIPTION,
|
164802
164766
|
description: ARIA_LABEL
|
164803
164767
|
};
|
164804
|
-
function ariaItemAttributes(
|
164768
|
+
function ariaItemAttributes(emit2, item) {
|
164805
164769
|
const hide = item.aria === false;
|
164806
|
-
|
164770
|
+
emit2(ARIA_HIDDEN, hide || void 0);
|
164807
164771
|
if (hide || item.description == null) {
|
164808
164772
|
for (const prop in AriaEncode) {
|
164809
|
-
|
164773
|
+
emit2(AriaEncode[prop], void 0);
|
164810
164774
|
}
|
164811
164775
|
} else {
|
164812
164776
|
const type2 = item.mark.marktype;
|
164813
|
-
|
164814
|
-
|
164815
|
-
|
164777
|
+
emit2(ARIA_LABEL, item.description);
|
164778
|
+
emit2(ARIA_ROLE, item.ariaRole || (type2 === "group" ? GRAPHICS_OBJECT : GRAPHICS_SYMBOL));
|
164779
|
+
emit2(ARIA_ROLEDESCRIPTION, item.ariaRoleDescription || "".concat(type2, " mark"));
|
164816
164780
|
}
|
164817
164781
|
}
|
164818
164782
|
function ariaMarkAttributes(mark2) {
|
@@ -165178,8 +165142,8 @@ inherits(SVGRenderer, Renderer, {
|
|
165178
165142
|
_update(mdef, el2, item) {
|
165179
165143
|
element$1 = el2;
|
165180
165144
|
values$3 = el2.__values__;
|
165181
|
-
ariaItemAttributes(
|
165182
|
-
mdef.attr(
|
165145
|
+
ariaItemAttributes(emit, item);
|
165146
|
+
mdef.attr(emit, item, this);
|
165183
165147
|
const extra = mark_extras[mdef.type];
|
165184
165148
|
if (extra)
|
165185
165149
|
extra.call(this, mdef, el2, item);
|
@@ -165366,12 +165330,12 @@ const mark_extras = {
|
|
165366
165330
|
group(mdef, el2, item) {
|
165367
165331
|
const fg = element$1 = el2.childNodes[2];
|
165368
165332
|
values$3 = fg.__values__;
|
165369
|
-
mdef.foreground(
|
165333
|
+
mdef.foreground(emit, item, this);
|
165370
165334
|
values$3 = el2.__values__;
|
165371
165335
|
element$1 = el2.childNodes[1];
|
165372
|
-
mdef.content(
|
165336
|
+
mdef.content(emit, item, this);
|
165373
165337
|
const bg = element$1 = el2.childNodes[0];
|
165374
|
-
mdef.background(
|
165338
|
+
mdef.background(emit, item, this);
|
165375
165339
|
const value2 = item.mark.interactive === false ? "none" : null;
|
165376
165340
|
if (value2 !== values$3.events) {
|
165377
165341
|
setAttribute(fg, "pointer-events", value2);
|
@@ -165438,7 +165402,7 @@ const mark_extras = {
|
|
165438
165402
|
setAttribute(el2, "font-weight", item.fontWeight);
|
165439
165403
|
}
|
165440
165404
|
};
|
165441
|
-
function
|
165405
|
+
function emit(name2, value2, ns2) {
|
165442
165406
|
if (value2 === values$3[name2])
|
165443
165407
|
return;
|
165444
165408
|
if (ns2) {
|
@@ -165617,13 +165581,13 @@ inherits(SVGStringRenderer, Renderer, {
|
|
165617
165581
|
* @param {string} tag - The tag being rendered.
|
165618
165582
|
*/
|
165619
165583
|
attr(scene, item, attrs, tag) {
|
165620
|
-
const object2 = {},
|
165584
|
+
const object2 = {}, emit2 = (name2, value2, ns2, prefixed2) => {
|
165621
165585
|
object2[prefixed2 || name2] = value2;
|
165622
165586
|
};
|
165623
165587
|
if (Array.isArray(attrs)) {
|
165624
|
-
attrs.forEach((fn) => fn(
|
165588
|
+
attrs.forEach((fn) => fn(emit2, item, this));
|
165625
165589
|
} else {
|
165626
|
-
attrs(
|
165590
|
+
attrs(emit2, item, this);
|
165627
165591
|
}
|
165628
165592
|
if (tag) {
|
165629
165593
|
style(object2, item, scene, tag, this._defs);
|
@@ -168674,7 +168638,7 @@ function clipRectangle(x02, y02, x12, y12) {
|
|
168674
168638
|
};
|
168675
168639
|
}
|
168676
168640
|
function graticuleX(y02, y12, dy) {
|
168677
|
-
var y2 = range$
|
168641
|
+
var y2 = range$5(y02, y12 - epsilon$3, dy).concat(y12);
|
168678
168642
|
return function(x2) {
|
168679
168643
|
return y2.map(function(y22) {
|
168680
168644
|
return [x2, y22];
|
@@ -168682,7 +168646,7 @@ function graticuleX(y02, y12, dy) {
|
|
168682
168646
|
};
|
168683
168647
|
}
|
168684
168648
|
function graticuleY(x02, x12, dx) {
|
168685
|
-
var x2 = range$
|
168649
|
+
var x2 = range$5(x02, x12 - epsilon$3, dx).concat(x12);
|
168686
168650
|
return function(y2) {
|
168687
168651
|
return x2.map(function(x22) {
|
168688
168652
|
return [x22, y2];
|
@@ -168695,9 +168659,9 @@ function graticule() {
|
|
168695
168659
|
return { type: "MultiLineString", coordinates: lines() };
|
168696
168660
|
}
|
168697
168661
|
function lines() {
|
168698
|
-
return range$
|
168662
|
+
return range$5(ceil(X02 / DX) * DX, X12, DX).map(X3).concat(range$5(ceil(Y02 / DY) * DY, Y12, DY).map(Y3)).concat(range$5(ceil(x02 / dx) * dx, x12, dx).filter(function(x22) {
|
168699
168663
|
return abs$1(x22 % DX) > epsilon$3;
|
168700
|
-
}).map(x2)).concat(range$
|
168664
|
+
}).map(x2)).concat(range$5(ceil(y02 / dy) * dy, y12, dy).filter(function(y22) {
|
168701
168665
|
return abs$1(y22 % DY) > epsilon$3;
|
168702
168666
|
}).map(y2));
|
168703
168667
|
}
|
@@ -170108,7 +170072,7 @@ inherits(Isocontour, Transform2, {
|
|
170108
170072
|
});
|
170109
170073
|
function levels(values2, f2, _) {
|
170110
170074
|
const q = quantize(_.levels || 10, _.nice, _.zero !== false);
|
170111
|
-
return _.resolve !== "shared" ? q : q(values2.map((t4) => max$
|
170075
|
+
return _.resolve !== "shared" ? q : q(values2.map((t4) => max$1(f2(t4).values)));
|
170112
170076
|
}
|
170113
170077
|
function transformPaths(paths, grid, datum2, _) {
|
170114
170078
|
let s2 = _.scale || grid.scale, t4 = _.translate || grid.translate;
|
@@ -170741,13 +170705,13 @@ inherits(Heatmap, Transform2, {
|
|
170741
170705
|
$x: 0,
|
170742
170706
|
$y: 0,
|
170743
170707
|
$value: 0,
|
170744
|
-
$max: shared ? max$
|
170708
|
+
$max: shared ? max$1(source2.map((t4) => max$1(field2(t4).values))) : 0
|
170745
170709
|
};
|
170746
170710
|
source2.forEach((t4) => {
|
170747
170711
|
const v = field2(t4);
|
170748
170712
|
const o2 = extend$1({}, t4, obj);
|
170749
170713
|
if (!shared)
|
170750
|
-
o2.$max = max$
|
170714
|
+
o2.$max = max$1(v.values || []);
|
170751
170715
|
t4[as] = toCanvas(v, o2, color2.dep ? color2 : constant$6(color2(o2)), opacity2.dep ? opacity2 : constant$6(opacity2(o2)));
|
170752
170716
|
});
|
170753
170717
|
return pulse2.reflow(true).modifies(as);
|
@@ -170783,7 +170747,7 @@ function dependency(f2) {
|
|
170783
170747
|
return set3.$x || set3.$y || set3.$value || set3.$max;
|
170784
170748
|
}
|
170785
170749
|
function toCanvas(grid, obj, color2, opacity2) {
|
170786
|
-
const n2 = grid.width, m2 = grid.height, x12 = grid.x1 || 0, y12 = grid.y1 || 0, x2 = grid.x2 || n2, y2 = grid.y2 || m2, val = grid.values, value2 = val ? (i2) => val[i2] : zero$
|
170750
|
+
const n2 = grid.width, m2 = grid.height, x12 = grid.x1 || 0, y12 = grid.y1 || 0, x2 = grid.x2 || n2, y2 = grid.y2 || m2, val = grid.values, value2 = val ? (i2) => val[i2] : zero$5, can = domCanvas(x2 - x12, y2 - y12), ctx = can.getContext("2d"), img = ctx.getImageData(0, 0, x2 - x12, y2 - y12), pix = img.data;
|
170787
170751
|
for (let j = y12, k = 0; j < y2; ++j) {
|
170788
170752
|
obj.$y = j - y12;
|
170789
170753
|
for (let i2 = x12, r3 = j * n2; i2 < x2; ++i2, k += 4) {
|
@@ -179586,14 +179550,14 @@ function hover(hoverSet, leaveSet) {
|
|
179586
179550
|
return this;
|
179587
179551
|
}
|
179588
179552
|
function finalize() {
|
179589
|
-
var tooltip2 = this._tooltip, timers = this._timers,
|
179553
|
+
var tooltip2 = this._tooltip, timers = this._timers, listeners = this._eventListeners, n2, m2, e3;
|
179590
179554
|
n2 = timers.length;
|
179591
179555
|
while (--n2 >= 0) {
|
179592
179556
|
timers[n2].stop();
|
179593
179557
|
}
|
179594
|
-
n2 =
|
179558
|
+
n2 = listeners.length;
|
179595
179559
|
while (--n2 >= 0) {
|
179596
|
-
e3 =
|
179560
|
+
e3 = listeners[n2];
|
179597
179561
|
m2 = e3.sources.length;
|
179598
179562
|
while (--m2 >= 0) {
|
179599
179563
|
e3.sources[m2].removeEventListener(e3.type, e3.handler);
|
@@ -183786,7 +183750,7 @@ const vegaImport = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.definePr
|
|
183786
183750
|
accessorFields,
|
183787
183751
|
accessorName,
|
183788
183752
|
array: array$6,
|
183789
|
-
ascending: ascending$
|
183753
|
+
ascending: ascending$4,
|
183790
183754
|
bandwidthNRD: estimateBandwidth,
|
183791
183755
|
bin: bin$1,
|
183792
183756
|
bootstrapCI,
|
@@ -183967,7 +183931,7 @@ const vegaImport = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.definePr
|
|
183967
183931
|
visitArray,
|
183968
183932
|
week,
|
183969
183933
|
writeConfig,
|
183970
|
-
zero: zero$
|
183934
|
+
zero: zero$5,
|
183971
183935
|
zoomLinear,
|
183972
183936
|
zoomLog,
|
183973
183937
|
zoomPow,
|
@@ -204077,9 +204041,9 @@ var debug_1 = debug$1;
|
|
204077
204041
|
var re2 = exports2.re = [];
|
204078
204042
|
var src = exports2.src = [];
|
204079
204043
|
var t4 = exports2.t = {};
|
204080
|
-
var
|
204044
|
+
var R = 0;
|
204081
204045
|
var createToken = (name2, value2, isGlobal) => {
|
204082
|
-
var index2 =
|
204046
|
+
var index2 = R++;
|
204083
204047
|
debug2(name2, index2, value2);
|
204084
204048
|
t4[name2] = index2;
|
204085
204049
|
src[index2] = value2;
|
@@ -207102,6 +207066,30 @@ function FeatureBarPlotSubscriber(props) {
|
|
207102
207066
|
}
|
207103
207067
|
);
|
207104
207068
|
}
|
207069
|
+
function createOrdinalScale(domainArr, rangeArr) {
|
207070
|
+
return (queryVal) => {
|
207071
|
+
const i2 = domainArr.findIndex((domainVal) => isEqual$2(domainVal, queryVal));
|
207072
|
+
return rangeArr[i2];
|
207073
|
+
};
|
207074
|
+
}
|
207075
|
+
function getColorScale(setSelectionArr, setColorArr, theme) {
|
207076
|
+
var _a2;
|
207077
|
+
const domainArr = setSelectionArr || [];
|
207078
|
+
const rangeArr = ((_a2 = setSelectionArr == null ? void 0 : setSelectionArr.map((setNamePath) => {
|
207079
|
+
var _a3;
|
207080
|
+
return ((_a3 = setColorArr == null ? void 0 : setColorArr.find((d) => isEqual$2(d.path, setNamePath))) == null ? void 0 : _a3.color) || getDefaultColor(theme);
|
207081
|
+
})) == null ? void 0 : _a2.map(colorArrayToString)) || [];
|
207082
|
+
return createOrdinalScale(domainArr, rangeArr);
|
207083
|
+
}
|
207084
|
+
function useRawSetPaths(columnNameMapping, setPaths) {
|
207085
|
+
return useMemo(() => setPaths == null ? void 0 : setPaths.map((setPath) => {
|
207086
|
+
const newSetPath = [...setPath];
|
207087
|
+
if ((newSetPath == null ? void 0 : newSetPath[0]) && columnNameMapping[newSetPath[0]]) {
|
207088
|
+
newSetPath[0] = columnNameMapping[newSetPath[0]];
|
207089
|
+
}
|
207090
|
+
return newSetPath;
|
207091
|
+
}), [columnNameMapping, setPaths]);
|
207092
|
+
}
|
207105
207093
|
function uidGenerator(prefix2) {
|
207106
207094
|
let i2 = 0;
|
207107
207095
|
return () => {
|
@@ -207109,15 +207097,6 @@ function uidGenerator(prefix2) {
|
|
207109
207097
|
return { id: `${prefix2}-${i2}`, href: `#${prefix2}-${i2}` };
|
207110
207098
|
};
|
207111
207099
|
}
|
207112
|
-
function getColorScale(setSelectionArr, setColorArr, theme) {
|
207113
|
-
var _a2;
|
207114
|
-
return ordinal$1().domain(setSelectionArr || []).range(
|
207115
|
-
((_a2 = setSelectionArr == null ? void 0 : setSelectionArr.map((setNamePath) => {
|
207116
|
-
var _a3;
|
207117
|
-
return ((_a3 = setColorArr == null ? void 0 : setColorArr.find((d) => isEqual$2(d.path, setNamePath))) == null ? void 0 : _a3.color) || getDefaultColor(theme);
|
207118
|
-
})) == null ? void 0 : _a2.map(colorArrayToString)) || []
|
207119
|
-
);
|
207120
|
-
}
|
207121
207100
|
function Treemap(props) {
|
207122
207101
|
const {
|
207123
207102
|
obsCounts,
|
@@ -207504,7 +207483,8 @@ function TreemapSubscriber(props) {
|
|
207504
207483
|
sampleSetColor,
|
207505
207484
|
mergedObsSets,
|
207506
207485
|
obsSetSelection,
|
207507
|
-
mergedSampleSets
|
207486
|
+
mergedSampleSets,
|
207487
|
+
sampleSetSelection
|
207508
207488
|
// TODO: consider filtering-related coordination values
|
207509
207489
|
]);
|
207510
207490
|
return /* @__PURE__ */ jsxRuntimeExports.jsx(
|
@@ -207549,6 +207529,1027 @@ function TreemapSubscriber(props) {
|
|
207549
207529
|
}
|
207550
207530
|
);
|
207551
207531
|
}
|
207532
|
+
function VolcanoPlot(props) {
|
207533
|
+
const {
|
207534
|
+
theme,
|
207535
|
+
width: width2,
|
207536
|
+
height: height2,
|
207537
|
+
obsType,
|
207538
|
+
featureType,
|
207539
|
+
obsSetsColumnNameMapping,
|
207540
|
+
sampleSetsColumnNameMapping,
|
207541
|
+
sampleSetSelection,
|
207542
|
+
obsSetSelection,
|
207543
|
+
obsSetColor,
|
207544
|
+
sampleSetColor,
|
207545
|
+
data: data2,
|
207546
|
+
marginTop = 5,
|
207547
|
+
marginRight = 5,
|
207548
|
+
marginLeft = 50,
|
207549
|
+
marginBottom = 50,
|
207550
|
+
onFeatureClick,
|
207551
|
+
featurePointSignificanceThreshold,
|
207552
|
+
featurePointFoldChangeThreshold,
|
207553
|
+
featureLabelSignificanceThreshold,
|
207554
|
+
featureLabelFoldChangeThreshold
|
207555
|
+
} = props;
|
207556
|
+
const svgRef = useRef();
|
207557
|
+
const computedData = useMemo(() => data2.map((d) => ({
|
207558
|
+
...d,
|
207559
|
+
df: {
|
207560
|
+
...d.df,
|
207561
|
+
minusLog10p: d.df.featureSignificance.map((v) => -Math.log10(v)),
|
207562
|
+
logFoldChange: d.df.featureFoldChange.map((v) => Math.log2(v))
|
207563
|
+
}
|
207564
|
+
})), [data2]);
|
207565
|
+
const [xExtent, yExtent] = useMemo(() => {
|
207566
|
+
if (!computedData) {
|
207567
|
+
return [null, null];
|
207568
|
+
}
|
207569
|
+
let xExtentResult = d3_extent(
|
207570
|
+
computedData.flatMap((d) => d3_extent(d.df.logFoldChange))
|
207571
|
+
);
|
207572
|
+
const xAbsMax = Math.max(Math.abs(xExtentResult[0]), Math.abs(xExtentResult[1]));
|
207573
|
+
xExtentResult = [-xAbsMax, xAbsMax];
|
207574
|
+
const yExtentResult = d3_extent(
|
207575
|
+
computedData.flatMap((d) => d3_extent(d.df.minusLog10p.filter((v) => Number.isFinite(v))))
|
207576
|
+
);
|
207577
|
+
return [xExtentResult, yExtentResult];
|
207578
|
+
}, [computedData]);
|
207579
|
+
const [obsSetColorScale, sampleSetColorScale] = useMemo(() => [
|
207580
|
+
getColorScale(obsSetSelection, obsSetColor, theme),
|
207581
|
+
getColorScale(sampleSetSelection, sampleSetColor, theme)
|
207582
|
+
], [obsSetSelection, sampleSetSelection, sampleSetColor, obsSetColor, theme]);
|
207583
|
+
useEffect(() => {
|
207584
|
+
var _a2;
|
207585
|
+
const domElement = svgRef.current;
|
207586
|
+
const svg = select$1(domElement);
|
207587
|
+
svg.selectAll("g").remove();
|
207588
|
+
svg.attr("width", width2).attr("height", height2).attr("viewBox", [0, 0, width2, height2]).attr("style", "font: 10px sans-serif");
|
207589
|
+
if (!computedData || !xExtent || !yExtent) {
|
207590
|
+
return;
|
207591
|
+
}
|
207592
|
+
const innerWidth = width2 - marginLeft;
|
207593
|
+
const innerHeight = height2 - marginBottom;
|
207594
|
+
const xScale = linear$4().range([marginLeft, width2 - marginRight]).domain(xExtent);
|
207595
|
+
const yScale = linear$4().domain(yExtent).range([innerHeight, marginTop]).clamp(true);
|
207596
|
+
svg.append("g").attr("transform", `translate(0,${height2 - marginBottom})`).call(axisBottom(xScale));
|
207597
|
+
svg.append("g").attr("transform", `translate(${marginLeft},0)`).call(axisLeft(yScale));
|
207598
|
+
const titleG = svg.append("g");
|
207599
|
+
const fgColor = "black";
|
207600
|
+
titleG.append("text").attr("text-anchor", "middle").attr("x", -innerHeight / 2).attr("y", 15).attr("transform", "rotate(-90)").text("-log10 p-value").style("font-size", "12px").style("fill", fgColor);
|
207601
|
+
titleG.append("text").attr("text-anchor", "middle").attr("x", marginLeft + innerWidth / 2).attr("y", height2 - 10).text("log2 fold-change").style("font-size", "12px").style("fill", fgColor);
|
207602
|
+
const obsSetsColumnNameMappingReversed = Object.fromEntries(
|
207603
|
+
Object.entries(obsSetsColumnNameMapping).map(([key2, value2]) => [value2, key2])
|
207604
|
+
);
|
207605
|
+
const sampleSetsColumnNameMappingReversed = Object.fromEntries(
|
207606
|
+
Object.entries(sampleSetsColumnNameMapping).map(([key2, value2]) => [value2, key2])
|
207607
|
+
);
|
207608
|
+
const ruleColor = "silver";
|
207609
|
+
const ruleDash = "2,2";
|
207610
|
+
titleG.append("line").attr("x1", xScale(featurePointFoldChangeThreshold)).attr("x2", xScale(featurePointFoldChangeThreshold)).attr("y1", yScale.range()[0]).attr("y2", yScale.range()[1]).style("stroke", ruleColor).style("stroke-dasharray", ruleDash);
|
207611
|
+
titleG.append("line").attr("x1", xScale(-featurePointFoldChangeThreshold)).attr("x2", xScale(-featurePointFoldChangeThreshold)).attr("y1", yScale.range()[0]).attr("y2", yScale.range()[1]).style("stroke", ruleColor).style("stroke-dasharray", ruleDash);
|
207612
|
+
titleG.append("line").attr("x1", xScale.range()[0]).attr("x2", xScale.range()[1]).attr("y1", yScale(-Math.log10(featurePointSignificanceThreshold))).attr("y2", yScale(-Math.log10(featurePointSignificanceThreshold))).style("stroke", ruleColor).style("stroke-dasharray", ruleDash);
|
207613
|
+
const lhsText = sampleSetSelection && sampleSetSelection.length === 2 ? sampleSetSelection[0].at(-1) : "__rest__";
|
207614
|
+
const rhsText = sampleSetSelection && sampleSetSelection.length === 2 ? sampleSetSelection[1].at(-1) : obsSetSelection && obsSetSelection.length === 1 ? (_a2 = obsSetSelection == null ? void 0 : obsSetSelection[0]) == null ? void 0 : _a2.at(-1) : `${capitalize$2(obsType)} Set`;
|
207615
|
+
titleG.append("text").attr("text-anchor", "start").attr("x", marginLeft).attr("y", height2 - 10).text(`← ${lhsText}`).style("font-size", "12px").style("fill", fgColor);
|
207616
|
+
titleG.append("text").attr("text-anchor", "end").attr("x", marginLeft + innerWidth).attr("y", height2 - 10).text(`${rhsText} →`).style("font-size", "12px").style("fill", fgColor);
|
207617
|
+
const g2 = svg.append("g");
|
207618
|
+
computedData.forEach((comparisonObject) => {
|
207619
|
+
const obsSetG = g2.append("g");
|
207620
|
+
const { df, metadata: metadata2 } = comparisonObject;
|
207621
|
+
const coordinationValues = metadata2.coordination_values;
|
207622
|
+
const rawObsSetPath = coordinationValues.obsSetFilter ? coordinationValues.obsSetFilter[0] : coordinationValues.obsSetSelection[0];
|
207623
|
+
const obsSetPath = [...rawObsSetPath];
|
207624
|
+
obsSetPath[0] = obsSetsColumnNameMappingReversed[rawObsSetPath[0]];
|
207625
|
+
let shouldSwapFoldChangeDirection = false;
|
207626
|
+
if (coordinationValues.sampleSetFilter && coordinationValues.sampleSetFilter.length === 2) {
|
207627
|
+
const rawSampleSetPathA = coordinationValues.sampleSetFilter[0];
|
207628
|
+
const sampleSetPathA = [...rawSampleSetPathA];
|
207629
|
+
sampleSetPathA[0] = sampleSetsColumnNameMappingReversed[rawSampleSetPathA[0]];
|
207630
|
+
const rawSampleSetPathB = coordinationValues.sampleSetFilter[1];
|
207631
|
+
const sampleSetPathB = [...rawSampleSetPathB];
|
207632
|
+
sampleSetPathB[0] = sampleSetsColumnNameMappingReversed[rawSampleSetPathB[0]];
|
207633
|
+
if (isEqual$2(sampleSetPathA, sampleSetSelection[1]) && isEqual$2(sampleSetPathB, sampleSetSelection[0])) {
|
207634
|
+
shouldSwapFoldChangeDirection = true;
|
207635
|
+
}
|
207636
|
+
}
|
207637
|
+
const filteredDf = df.featureId.map((featureId, i2) => ({
|
207638
|
+
featureId,
|
207639
|
+
logFoldChange: df.logFoldChange[i2] * (shouldSwapFoldChangeDirection ? -1 : 1),
|
207640
|
+
featureSignificance: df.featureSignificance[i2],
|
207641
|
+
minusLog10p: df.minusLog10p[i2]
|
207642
|
+
})).filter((d) => Math.abs(d.logFoldChange) >= (featurePointFoldChangeThreshold ?? 1) && d.featureSignificance <= (featurePointSignificanceThreshold ?? 0.05));
|
207643
|
+
const color2 = obsSetColorScale(obsSetPath);
|
207644
|
+
obsSetG.append("g").selectAll("circle").data(filteredDf).join("circle").attr("cx", (d) => xScale(d.logFoldChange)).attr("cy", (d) => yScale(d.minusLog10p)).attr("r", 3).attr("opacity", 0.5).attr("fill", color2).on("click", (event2, d) => {
|
207645
|
+
onFeatureClick(d.featureId);
|
207646
|
+
});
|
207647
|
+
const textElements = obsSetG.append("g").selectAll("text").data(filteredDf).join("text").text((d) => d.featureId).attr("text-anchor", (d) => d.logFoldChange < 0 ? "end" : "start").attr("x", (d) => xScale(d.logFoldChange)).attr("y", (d) => yScale(d.minusLog10p)).style("display", (d) => Math.abs(d.logFoldChange) < (featureLabelFoldChangeThreshold ?? 5) || d.featureSignificance >= (featureLabelSignificanceThreshold ?? 0.01) ? "none" : void 0).attr("fill", color2).on("click", (event2, d) => {
|
207648
|
+
onFeatureClick(d.featureId);
|
207649
|
+
});
|
207650
|
+
textElements.append("title").text((d) => `${featureType}: ${d.featureId}
|
207651
|
+
in ${obsSetPath == null ? void 0 : obsSetPath.at(-1)}
|
207652
|
+
log2 fold-change: ${d.logFoldChange}
|
207653
|
+
p-value: ${d.featureSignificance}`);
|
207654
|
+
});
|
207655
|
+
}, [
|
207656
|
+
width2,
|
207657
|
+
height2,
|
207658
|
+
theme,
|
207659
|
+
sampleSetColor,
|
207660
|
+
sampleSetSelection,
|
207661
|
+
obsSetSelection,
|
207662
|
+
obsSetColor,
|
207663
|
+
featureType,
|
207664
|
+
computedData,
|
207665
|
+
xExtent,
|
207666
|
+
yExtent,
|
207667
|
+
obsType,
|
207668
|
+
marginLeft,
|
207669
|
+
marginBottom,
|
207670
|
+
marginTop,
|
207671
|
+
marginRight,
|
207672
|
+
obsSetColorScale,
|
207673
|
+
sampleSetColorScale,
|
207674
|
+
onFeatureClick,
|
207675
|
+
featurePointSignificanceThreshold,
|
207676
|
+
featurePointFoldChangeThreshold,
|
207677
|
+
featureLabelSignificanceThreshold,
|
207678
|
+
featureLabelFoldChangeThreshold
|
207679
|
+
]);
|
207680
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(
|
207681
|
+
"svg",
|
207682
|
+
{
|
207683
|
+
ref: svgRef,
|
207684
|
+
style: {
|
207685
|
+
top: 0,
|
207686
|
+
left: 0,
|
207687
|
+
width: `${width2}px`,
|
207688
|
+
height: `${height2}px`,
|
207689
|
+
position: "relative"
|
207690
|
+
}
|
207691
|
+
}
|
207692
|
+
);
|
207693
|
+
}
|
207694
|
+
function VolcanoPlotOptions(props) {
|
207695
|
+
const {
|
207696
|
+
children: children2,
|
207697
|
+
featurePointSignificanceThreshold,
|
207698
|
+
featurePointFoldChangeThreshold,
|
207699
|
+
featureLabelSignificanceThreshold,
|
207700
|
+
featureLabelFoldChangeThreshold,
|
207701
|
+
setFeaturePointSignificanceThreshold,
|
207702
|
+
setFeaturePointFoldChangeThreshold,
|
207703
|
+
setFeatureLabelSignificanceThreshold,
|
207704
|
+
setFeatureLabelFoldChangeThreshold
|
207705
|
+
} = props;
|
207706
|
+
const volcanoOptionsId = $bdb11010cef70236$export$f680877a34711e37();
|
207707
|
+
const classes = usePlotOptionsStyles();
|
207708
|
+
function handlePointSignificanceChange(event2, value2) {
|
207709
|
+
setFeaturePointSignificanceThreshold(10 ** -value2);
|
207710
|
+
}
|
207711
|
+
function handlePointFoldChangeChange(event2, value2) {
|
207712
|
+
setFeaturePointFoldChangeThreshold(value2);
|
207713
|
+
}
|
207714
|
+
function handleLabelSignificanceChange(event2, value2) {
|
207715
|
+
setFeatureLabelSignificanceThreshold(10 ** -value2);
|
207716
|
+
}
|
207717
|
+
function handleLabelFoldChangeChange(event2, value2) {
|
207718
|
+
setFeatureLabelFoldChangeThreshold(value2);
|
207719
|
+
}
|
207720
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsxs(OptionsContainer, { children: [
|
207721
|
+
children2,
|
207722
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs(TableRow$1, { children: [
|
207723
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(TableCell$1, { className: classes.labelCell, variant: "head", scope: "row", children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
207724
|
+
"label",
|
207725
|
+
{
|
207726
|
+
htmlFor: `volcano-label-significance-${volcanoOptionsId}`,
|
207727
|
+
children: "Label Significance Threshold"
|
207728
|
+
}
|
207729
|
+
) }),
|
207730
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(TableCell$1, { className: classes.inputCell, variant: "body", children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
207731
|
+
Slider$1,
|
207732
|
+
{
|
207733
|
+
classes: { root: classes.slider, valueLabel: classes.sliderValueLabel },
|
207734
|
+
value: -Math.log10(featureLabelSignificanceThreshold),
|
207735
|
+
onChange: handleLabelSignificanceChange,
|
207736
|
+
"aria-label": "Volcano plot label significance threshold slider",
|
207737
|
+
id: `volcano-label-significance-${volcanoOptionsId}`,
|
207738
|
+
valueLabelDisplay: "auto",
|
207739
|
+
step: 1,
|
207740
|
+
min: 0,
|
207741
|
+
max: 100
|
207742
|
+
}
|
207743
|
+
) })
|
207744
|
+
] }),
|
207745
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs(TableRow$1, { children: [
|
207746
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(TableCell$1, { className: classes.labelCell, variant: "head", scope: "row", children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
207747
|
+
"label",
|
207748
|
+
{
|
207749
|
+
htmlFor: `volcano-label-fc-${volcanoOptionsId}`,
|
207750
|
+
children: "Label Fold-Change Threshold"
|
207751
|
+
}
|
207752
|
+
) }),
|
207753
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(TableCell$1, { className: classes.inputCell, variant: "body", children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
207754
|
+
Slider$1,
|
207755
|
+
{
|
207756
|
+
classes: { root: classes.slider, valueLabel: classes.sliderValueLabel },
|
207757
|
+
value: featureLabelFoldChangeThreshold,
|
207758
|
+
onChange: handleLabelFoldChangeChange,
|
207759
|
+
"aria-label": "Volcano plot label fold-change threshold slider",
|
207760
|
+
id: `volcano-label-fc-${volcanoOptionsId}`,
|
207761
|
+
valueLabelDisplay: "auto",
|
207762
|
+
step: 0.5,
|
207763
|
+
min: 0,
|
207764
|
+
max: 50
|
207765
|
+
}
|
207766
|
+
) })
|
207767
|
+
] }),
|
207768
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs(TableRow$1, { children: [
|
207769
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(TableCell$1, { className: classes.labelCell, variant: "head", scope: "row", children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
207770
|
+
"label",
|
207771
|
+
{
|
207772
|
+
htmlFor: `volcano-point-significance-${volcanoOptionsId}`,
|
207773
|
+
children: "Point Significance Threshold"
|
207774
|
+
}
|
207775
|
+
) }),
|
207776
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(TableCell$1, { className: classes.inputCell, variant: "body", children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
207777
|
+
Slider$1,
|
207778
|
+
{
|
207779
|
+
classes: { root: classes.slider, valueLabel: classes.sliderValueLabel },
|
207780
|
+
value: -Math.log10(featurePointSignificanceThreshold),
|
207781
|
+
onChange: handlePointSignificanceChange,
|
207782
|
+
"aria-label": "Volcano plot point significance threshold slider",
|
207783
|
+
id: `volcano-point-significance-${volcanoOptionsId}`,
|
207784
|
+
valueLabelDisplay: "auto",
|
207785
|
+
step: 1,
|
207786
|
+
min: 0,
|
207787
|
+
max: 100
|
207788
|
+
}
|
207789
|
+
) })
|
207790
|
+
] }),
|
207791
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs(TableRow$1, { children: [
|
207792
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(TableCell$1, { className: classes.labelCell, variant: "head", scope: "row", children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
207793
|
+
"label",
|
207794
|
+
{
|
207795
|
+
htmlFor: `volcano-point-fc-${volcanoOptionsId}`,
|
207796
|
+
children: "Point Fold-Change Threshold"
|
207797
|
+
}
|
207798
|
+
) }),
|
207799
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(TableCell$1, { className: classes.inputCell, variant: "body", children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
207800
|
+
Slider$1,
|
207801
|
+
{
|
207802
|
+
classes: { root: classes.slider, valueLabel: classes.sliderValueLabel },
|
207803
|
+
value: featurePointFoldChangeThreshold,
|
207804
|
+
onChange: handlePointFoldChangeChange,
|
207805
|
+
"aria-label": "Volcano plot point fold-change threshold slider",
|
207806
|
+
id: `volcano-point-fc-${volcanoOptionsId}`,
|
207807
|
+
valueLabelDisplay: "auto",
|
207808
|
+
step: 0.5,
|
207809
|
+
min: 0,
|
207810
|
+
max: 50
|
207811
|
+
}
|
207812
|
+
) })
|
207813
|
+
] })
|
207814
|
+
] });
|
207815
|
+
}
|
207816
|
+
function VolcanoPlotSubscriber(props) {
|
207817
|
+
const {
|
207818
|
+
coordinationScopes,
|
207819
|
+
removeGridComponent,
|
207820
|
+
theme,
|
207821
|
+
helpText = ViewHelpMapping.VOLCANO_PLOT
|
207822
|
+
} = props;
|
207823
|
+
const classes = useStyles$1();
|
207824
|
+
const loaders = useLoaders();
|
207825
|
+
const [{
|
207826
|
+
dataset,
|
207827
|
+
obsType,
|
207828
|
+
sampleType,
|
207829
|
+
featureType,
|
207830
|
+
featureValueType,
|
207831
|
+
obsFilter: cellFilter,
|
207832
|
+
obsHighlight: cellHighlight,
|
207833
|
+
obsSetSelection,
|
207834
|
+
obsSetColor,
|
207835
|
+
obsColorEncoding: cellColorEncoding,
|
207836
|
+
additionalObsSets: additionalCellSets,
|
207837
|
+
featurePointSignificanceThreshold,
|
207838
|
+
featurePointFoldChangeThreshold,
|
207839
|
+
featureLabelSignificanceThreshold,
|
207840
|
+
featureLabelFoldChangeThreshold,
|
207841
|
+
featureValueTransform,
|
207842
|
+
featureValueTransformCoefficient,
|
207843
|
+
gatingFeatureSelectionX,
|
207844
|
+
gatingFeatureSelectionY,
|
207845
|
+
featureSelection,
|
207846
|
+
sampleSetSelection,
|
207847
|
+
sampleSetColor
|
207848
|
+
}, {
|
207849
|
+
setObsFilter: setCellFilter,
|
207850
|
+
setObsSetSelection,
|
207851
|
+
setObsHighlight: setCellHighlight,
|
207852
|
+
setObsSetColor: setCellSetColor,
|
207853
|
+
setObsColorEncoding: setCellColorEncoding,
|
207854
|
+
setAdditionalObsSets: setAdditionalCellSets,
|
207855
|
+
setFeaturePointSignificanceThreshold,
|
207856
|
+
setFeaturePointFoldChangeThreshold,
|
207857
|
+
setFeatureLabelSignificanceThreshold,
|
207858
|
+
setFeatureLabelFoldChangeThreshold,
|
207859
|
+
setFeatureValueTransform,
|
207860
|
+
setFeatureValueTransformCoefficient,
|
207861
|
+
setGatingFeatureSelectionX,
|
207862
|
+
setGatingFeatureSelectionY,
|
207863
|
+
setFeatureSelection,
|
207864
|
+
setSampleSetSelection,
|
207865
|
+
setSampleSetColor
|
207866
|
+
}] = useCoordination(
|
207867
|
+
COMPONENT_COORDINATION_TYPES[ViewType$1.VOLCANO_PLOT],
|
207868
|
+
coordinationScopes
|
207869
|
+
);
|
207870
|
+
const [width2, height2, containerRef] = useGridItemSize();
|
207871
|
+
const obsSetsLoader = useMatchingLoader(
|
207872
|
+
loaders,
|
207873
|
+
dataset,
|
207874
|
+
DataType$2.OBS_SETS,
|
207875
|
+
{ obsType }
|
207876
|
+
);
|
207877
|
+
const sampleSetsLoader = useMatchingLoader(
|
207878
|
+
loaders,
|
207879
|
+
dataset,
|
207880
|
+
DataType$2.SAMPLE_SETS,
|
207881
|
+
{ sampleType }
|
207882
|
+
);
|
207883
|
+
const obsSetsColumnNameMapping = useColumnNameMapping(obsSetsLoader);
|
207884
|
+
const sampleSetsColumnNameMapping = useColumnNameMapping(sampleSetsLoader);
|
207885
|
+
const rawSampleSetSelection = useRawSetPaths(sampleSetsColumnNameMapping, sampleSetSelection);
|
207886
|
+
const rawObsSetSelection = useRawSetPaths(obsSetsColumnNameMapping, obsSetSelection);
|
207887
|
+
const [{ featureStats }, featureStatsStatus] = useFeatureStatsData(
|
207888
|
+
loaders,
|
207889
|
+
dataset,
|
207890
|
+
false,
|
207891
|
+
{ obsType, featureType, sampleType },
|
207892
|
+
// These volcanoOptions are passed to FeatureStatsAnndataLoader.loadMulti():
|
207893
|
+
{ sampleSetSelection: rawSampleSetSelection, obsSetSelection: rawObsSetSelection }
|
207894
|
+
);
|
207895
|
+
const isReady = useReady([
|
207896
|
+
featureStatsStatus
|
207897
|
+
]);
|
207898
|
+
const onFeatureClick = useCallback((featureId) => {
|
207899
|
+
setFeatureSelection([featureId]);
|
207900
|
+
}, [setFeatureSelection]);
|
207901
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(
|
207902
|
+
TitleInfo,
|
207903
|
+
{
|
207904
|
+
title: "Volcano Plot",
|
207905
|
+
removeGridComponent,
|
207906
|
+
theme,
|
207907
|
+
isReady,
|
207908
|
+
helpText,
|
207909
|
+
options: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
207910
|
+
VolcanoPlotOptions,
|
207911
|
+
{
|
207912
|
+
obsType,
|
207913
|
+
featureType,
|
207914
|
+
featurePointSignificanceThreshold,
|
207915
|
+
featurePointFoldChangeThreshold,
|
207916
|
+
featureLabelSignificanceThreshold,
|
207917
|
+
featureLabelFoldChangeThreshold,
|
207918
|
+
setFeaturePointSignificanceThreshold,
|
207919
|
+
setFeaturePointFoldChangeThreshold,
|
207920
|
+
setFeatureLabelSignificanceThreshold,
|
207921
|
+
setFeatureLabelFoldChangeThreshold
|
207922
|
+
}
|
207923
|
+
),
|
207924
|
+
children: /* @__PURE__ */ jsxRuntimeExports.jsx("div", { ref: containerRef, className: classes.vegaContainer, children: featureStats ? /* @__PURE__ */ jsxRuntimeExports.jsx(
|
207925
|
+
VolcanoPlot,
|
207926
|
+
{
|
207927
|
+
theme,
|
207928
|
+
width: width2,
|
207929
|
+
height: height2,
|
207930
|
+
obsType,
|
207931
|
+
featureType,
|
207932
|
+
obsSetsColumnNameMapping,
|
207933
|
+
sampleSetsColumnNameMapping,
|
207934
|
+
sampleSetSelection,
|
207935
|
+
obsSetSelection,
|
207936
|
+
obsSetColor,
|
207937
|
+
sampleSetColor,
|
207938
|
+
data: featureStats,
|
207939
|
+
onFeatureClick,
|
207940
|
+
featurePointSignificanceThreshold,
|
207941
|
+
featurePointFoldChangeThreshold,
|
207942
|
+
featureLabelSignificanceThreshold,
|
207943
|
+
featureLabelFoldChangeThreshold
|
207944
|
+
}
|
207945
|
+
) : /* @__PURE__ */ jsxRuntimeExports.jsxs("span", { children: [
|
207946
|
+
"Select at least one ",
|
207947
|
+
obsType,
|
207948
|
+
" set."
|
207949
|
+
] }) })
|
207950
|
+
}
|
207951
|
+
);
|
207952
|
+
}
|
207953
|
+
function CellSetCompositionBarPlot(props) {
|
207954
|
+
const {
|
207955
|
+
data: data2,
|
207956
|
+
theme,
|
207957
|
+
width: width2,
|
207958
|
+
height: height2,
|
207959
|
+
marginRight = 200,
|
207960
|
+
marginBottom = 120,
|
207961
|
+
keyLength = 36,
|
207962
|
+
obsType,
|
207963
|
+
onBarSelect,
|
207964
|
+
obsSetsColumnNameMappingReversed,
|
207965
|
+
sampleSetsColumnNameMappingReversed,
|
207966
|
+
sampleSetSelection,
|
207967
|
+
obsSetSelection,
|
207968
|
+
obsSetColor,
|
207969
|
+
sampleSetColor
|
207970
|
+
} = props;
|
207971
|
+
const [obsSetColorScale, sampleSetColorScale] = useMemo(() => [
|
207972
|
+
getColorScale(obsSetSelection, obsSetColor, theme),
|
207973
|
+
getColorScale(sampleSetSelection, sampleSetColor, theme)
|
207974
|
+
], [obsSetSelection, sampleSetSelection, sampleSetColor, obsSetColor, theme]);
|
207975
|
+
const computedData = useMemo(() => {
|
207976
|
+
var _a2, _b, _c, _d, _e, _f, _g;
|
207977
|
+
if (Array.isArray(data2) && data2.length === 1) {
|
207978
|
+
const { df, metadata: metadata2 } = data2[0];
|
207979
|
+
const referenceCellType = (_a2 = metadata2 == null ? void 0 : metadata2.analysis_params) == null ? void 0 : _a2.reference_cell_type;
|
207980
|
+
const coordinationValues = metadata2 == null ? void 0 : metadata2.coordination_values;
|
207981
|
+
const obsSetColumnName = (_c = (_b = coordinationValues == null ? void 0 : coordinationValues.obsSetSelection) == null ? void 0 : _b[0]) == null ? void 0 : _c[0];
|
207982
|
+
const obsSetGroupName = obsSetsColumnNameMappingReversed == null ? void 0 : obsSetsColumnNameMappingReversed[obsSetColumnName];
|
207983
|
+
const sampleSetColumnName = (_e = (_d = coordinationValues == null ? void 0 : coordinationValues.sampleSetFilter) == null ? void 0 : _d[0]) == null ? void 0 : _e[0];
|
207984
|
+
const sampleSetGroupName = sampleSetsColumnNameMappingReversed == null ? void 0 : sampleSetsColumnNameMappingReversed[sampleSetColumnName];
|
207985
|
+
const covariatePrefix = `${sampleSetColumnName}T.`;
|
207986
|
+
const firstCovariateValue = (_g = (_f = df.covariate) == null ? void 0 : _f[0]) == null ? void 0 : _g.substring(covariatePrefix.length);
|
207987
|
+
const firstCovariateSetPath = [sampleSetGroupName, firstCovariateValue];
|
207988
|
+
let shouldSwapFoldChangeDirection = false;
|
207989
|
+
if (isEqual$2(firstCovariateSetPath, sampleSetSelection[0])) {
|
207990
|
+
shouldSwapFoldChangeDirection = true;
|
207991
|
+
}
|
207992
|
+
return df.obsSetId.map((obsSetId, i2) => {
|
207993
|
+
const key2 = v4$1();
|
207994
|
+
const isReferenceSet = obsSetId === referenceCellType;
|
207995
|
+
const name2 = `${obsSetId}${isReferenceSet ? " (reference set)" : ""}`;
|
207996
|
+
const obsSetPath = [obsSetGroupName, obsSetId];
|
207997
|
+
const color2 = obsSetColorScale(obsSetPath);
|
207998
|
+
return {
|
207999
|
+
name: name2,
|
208000
|
+
// Reconstruct set path array.
|
208001
|
+
obsSetPath,
|
208002
|
+
color: color2,
|
208003
|
+
// Unique key per bar
|
208004
|
+
key: key2,
|
208005
|
+
// Add a property `keyName` which concatenates the key and the name,
|
208006
|
+
// which is both unique and can easily be converted
|
208007
|
+
// back to the name by taking a substring.
|
208008
|
+
keyName: `${key2}${name2}`,
|
208009
|
+
// Swap direction of foldChange/logFC if necessary
|
208010
|
+
obsSetFoldChange: df.obsSetFoldChange[i2] * (shouldSwapFoldChangeDirection ? -1 : 1),
|
208011
|
+
logFoldChange: Math.log2(df.obsSetFoldChange[i2]) * (shouldSwapFoldChangeDirection ? -1 : 1),
|
208012
|
+
interceptExpectedSample: df.interceptExpectedSample[i2],
|
208013
|
+
effectExpectedSample: df.effectExpectedSample[i2],
|
208014
|
+
isCredibleEffect: df.isCredibleEffect[i2],
|
208015
|
+
// Boolean flag for wasReferenceObsSet (check metadata)
|
208016
|
+
isReferenceSet: obsSetId === referenceCellType
|
208017
|
+
};
|
208018
|
+
}).filter((d) => obsSetSelection == null ? void 0 : obsSetSelection.find((setNamePath) => isEqual$2(setNamePath, d.obsSetPath)));
|
208019
|
+
}
|
208020
|
+
return null;
|
208021
|
+
}, [
|
208022
|
+
data2,
|
208023
|
+
sampleSetSelection,
|
208024
|
+
obsSetsColumnNameMappingReversed,
|
208025
|
+
sampleSetsColumnNameMappingReversed,
|
208026
|
+
obsSetSelection,
|
208027
|
+
obsSetColorScale,
|
208028
|
+
sampleSetColorScale
|
208029
|
+
]);
|
208030
|
+
const keys3 = computedData.map((d) => d.keyName);
|
208031
|
+
const colorScale2 = {
|
208032
|
+
// Manually set the color scale so that Vega-Lite does
|
208033
|
+
// not choose the colors automatically.
|
208034
|
+
domain: computedData.map((d) => d.key),
|
208035
|
+
range: computedData.map((d) => d.color)
|
208036
|
+
};
|
208037
|
+
const captializedObsType = capitalize$2(obsType);
|
208038
|
+
const opacityScale = {
|
208039
|
+
domain: [true, false],
|
208040
|
+
range: [1, 0.3]
|
208041
|
+
};
|
208042
|
+
const strokeWidthScale = {
|
208043
|
+
domain: [true, false],
|
208044
|
+
range: [2, 0.5]
|
208045
|
+
};
|
208046
|
+
const spec = {
|
208047
|
+
mark: { type: "bar", stroke: "black", cursor: "pointer" },
|
208048
|
+
params: [
|
208049
|
+
{
|
208050
|
+
name: "bar_select",
|
208051
|
+
select: {
|
208052
|
+
type: "point",
|
208053
|
+
on: "click[event.shiftKey === false]",
|
208054
|
+
fields: ["obsSetPath"],
|
208055
|
+
empty: "none"
|
208056
|
+
}
|
208057
|
+
},
|
208058
|
+
{
|
208059
|
+
name: "shift_bar_select",
|
208060
|
+
select: {
|
208061
|
+
type: "point",
|
208062
|
+
on: "click[event.shiftKey]",
|
208063
|
+
fields: ["obsSetPath"],
|
208064
|
+
empty: "none"
|
208065
|
+
}
|
208066
|
+
}
|
208067
|
+
],
|
208068
|
+
encoding: {
|
208069
|
+
y: {
|
208070
|
+
field: "keyName",
|
208071
|
+
type: "nominal",
|
208072
|
+
axis: { labelExpr: `substring(datum.label, ${keyLength})` },
|
208073
|
+
title: `${captializedObsType} Set`,
|
208074
|
+
sort: keys3
|
208075
|
+
},
|
208076
|
+
x: {
|
208077
|
+
// TODO: support using intercept+effect here based on user-selected options?
|
208078
|
+
field: "logFoldChange",
|
208079
|
+
type: "quantitative",
|
208080
|
+
title: "Log fold-change"
|
208081
|
+
},
|
208082
|
+
color: {
|
208083
|
+
field: "key",
|
208084
|
+
type: "nominal",
|
208085
|
+
scale: colorScale2,
|
208086
|
+
legend: null
|
208087
|
+
},
|
208088
|
+
fillOpacity: {
|
208089
|
+
field: "isCredibleEffect",
|
208090
|
+
type: "nominal",
|
208091
|
+
scale: opacityScale
|
208092
|
+
},
|
208093
|
+
strokeWidth: {
|
208094
|
+
field: "isReferenceSet",
|
208095
|
+
type: "nominal",
|
208096
|
+
scale: strokeWidthScale
|
208097
|
+
},
|
208098
|
+
tooltip: {
|
208099
|
+
field: "effectExpectedSample",
|
208100
|
+
type: "quantitative"
|
208101
|
+
}
|
208102
|
+
},
|
208103
|
+
// TODO: for width, also subtract length of longest y-axis set name label.
|
208104
|
+
width: clamp$5(width2 - marginRight, 10, Infinity),
|
208105
|
+
height: clamp$5(height2 - marginBottom, 10, Infinity),
|
208106
|
+
config: VEGA_THEMES[theme]
|
208107
|
+
};
|
208108
|
+
const handleSignal = (name2, value2) => {
|
208109
|
+
if (name2 === "bar_select") {
|
208110
|
+
onBarSelect(value2.obsSetPath);
|
208111
|
+
} else if (name2 === "shift_bar_select") {
|
208112
|
+
onBarSelect(value2.obsSetPath, true);
|
208113
|
+
}
|
208114
|
+
};
|
208115
|
+
const signalListeners = { bar_select: handleSignal, shift_bar_select: handleSignal };
|
208116
|
+
const getTooltipText = useCallback((item) => ({
|
208117
|
+
[`${captializedObsType} Set`]: item.datum.name,
|
208118
|
+
"Log fold-change": item.datum.logFoldChange,
|
208119
|
+
interceptExpectedSample: item.datum.interceptExpectedSample,
|
208120
|
+
effectExpectedSample: item.datum.effectExpectedSample
|
208121
|
+
}), [captializedObsType]);
|
208122
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(
|
208123
|
+
VegaPlot,
|
208124
|
+
{
|
208125
|
+
data: computedData,
|
208126
|
+
spec,
|
208127
|
+
signalListeners,
|
208128
|
+
getTooltipText
|
208129
|
+
}
|
208130
|
+
);
|
208131
|
+
}
|
208132
|
+
function CellSetCompositionBarPlotSubscriber(props) {
|
208133
|
+
const {
|
208134
|
+
coordinationScopes,
|
208135
|
+
removeGridComponent,
|
208136
|
+
theme,
|
208137
|
+
helpText = ViewHelpMapping.OBS_SET_COMPOSITION_BAR_PLOT
|
208138
|
+
} = props;
|
208139
|
+
const classes = useStyles$1();
|
208140
|
+
const loaders = useLoaders();
|
208141
|
+
const [{
|
208142
|
+
dataset,
|
208143
|
+
obsType,
|
208144
|
+
sampleType,
|
208145
|
+
featureType,
|
208146
|
+
featureValueType,
|
208147
|
+
obsFilter: cellFilter,
|
208148
|
+
obsHighlight: cellHighlight,
|
208149
|
+
obsSetSelection,
|
208150
|
+
obsSetColor,
|
208151
|
+
obsColorEncoding: cellColorEncoding,
|
208152
|
+
additionalObsSets: additionalCellSets,
|
208153
|
+
featurePointSignificanceThreshold,
|
208154
|
+
featurePointFoldChangeThreshold,
|
208155
|
+
featureLabelSignificanceThreshold,
|
208156
|
+
featureLabelFoldChangeThreshold,
|
208157
|
+
featureValueTransform,
|
208158
|
+
featureValueTransformCoefficient,
|
208159
|
+
gatingFeatureSelectionX,
|
208160
|
+
gatingFeatureSelectionY,
|
208161
|
+
featureSelection,
|
208162
|
+
sampleSetSelection,
|
208163
|
+
sampleSetColor
|
208164
|
+
}, {
|
208165
|
+
setObsFilter: setCellFilter,
|
208166
|
+
setObsSetSelection,
|
208167
|
+
setObsHighlight: setCellHighlight,
|
208168
|
+
setObsSetColor: setCellSetColor,
|
208169
|
+
setObsColorEncoding: setCellColorEncoding,
|
208170
|
+
setAdditionalObsSets: setAdditionalCellSets,
|
208171
|
+
setFeaturePointSignificanceThreshold,
|
208172
|
+
setFeaturePointFoldChangeThreshold,
|
208173
|
+
setFeatureLabelSignificanceThreshold,
|
208174
|
+
setFeatureLabelFoldChangeThreshold,
|
208175
|
+
setFeatureValueTransform,
|
208176
|
+
setFeatureValueTransformCoefficient,
|
208177
|
+
setGatingFeatureSelectionX,
|
208178
|
+
setGatingFeatureSelectionY,
|
208179
|
+
setFeatureSelection,
|
208180
|
+
setSampleSetSelection,
|
208181
|
+
setSampleSetColor
|
208182
|
+
}] = useCoordination(
|
208183
|
+
COMPONENT_COORDINATION_TYPES[ViewType$1.OBS_SET_COMPOSITION_BAR_PLOT],
|
208184
|
+
coordinationScopes
|
208185
|
+
);
|
208186
|
+
const [width2, height2, containerRef] = useGridItemSize();
|
208187
|
+
const obsSetsLoader = useMatchingLoader(
|
208188
|
+
loaders,
|
208189
|
+
dataset,
|
208190
|
+
DataType$2.OBS_SETS,
|
208191
|
+
{ obsType }
|
208192
|
+
);
|
208193
|
+
const sampleSetsLoader = useMatchingLoader(
|
208194
|
+
loaders,
|
208195
|
+
dataset,
|
208196
|
+
DataType$2.SAMPLE_SETS,
|
208197
|
+
{ sampleType }
|
208198
|
+
);
|
208199
|
+
const obsSetsColumnNameMapping = useColumnNameMapping(obsSetsLoader);
|
208200
|
+
const obsSetsColumnNameMappingReversed = useColumnNameMapping(obsSetsLoader, true);
|
208201
|
+
const sampleSetsColumnNameMapping = useColumnNameMapping(sampleSetsLoader);
|
208202
|
+
const sampleSetsColumnNameMappingReversed = useColumnNameMapping(sampleSetsLoader, true);
|
208203
|
+
const rawSampleSetSelection = useRawSetPaths(sampleSetsColumnNameMapping, sampleSetSelection);
|
208204
|
+
const rawObsSetSelection = useRawSetPaths(obsSetsColumnNameMapping, obsSetSelection);
|
208205
|
+
const [{ obsSetStats }, obsSetStatsStatus] = useObsSetStatsData(
|
208206
|
+
loaders,
|
208207
|
+
dataset,
|
208208
|
+
false,
|
208209
|
+
{ obsType, sampleType },
|
208210
|
+
// These volcanoOptions are passed to ObsSetStatsAnndataLoader.loadMulti():
|
208211
|
+
{ sampleSetSelection: rawSampleSetSelection, obsSetSelection: rawObsSetSelection }
|
208212
|
+
);
|
208213
|
+
const isReady = useReady([
|
208214
|
+
obsSetStatsStatus
|
208215
|
+
]);
|
208216
|
+
const onBarSelect = useCallback((setNamePath, isShiftDown = false) => {
|
208217
|
+
setObsSetSelection([setNamePath]);
|
208218
|
+
}, [setObsSetSelection]);
|
208219
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(
|
208220
|
+
TitleInfo,
|
208221
|
+
{
|
208222
|
+
title: `${capitalize$2(obsType)} Set Composition Analysis Plot`,
|
208223
|
+
removeGridComponent,
|
208224
|
+
theme,
|
208225
|
+
isReady,
|
208226
|
+
helpText,
|
208227
|
+
children: /* @__PURE__ */ jsxRuntimeExports.jsx("div", { ref: containerRef, className: classes.vegaContainer, children: obsSetStats ? /* @__PURE__ */ jsxRuntimeExports.jsx(
|
208228
|
+
CellSetCompositionBarPlot,
|
208229
|
+
{
|
208230
|
+
theme,
|
208231
|
+
width: width2,
|
208232
|
+
height: height2,
|
208233
|
+
obsType,
|
208234
|
+
obsSetsColumnNameMapping,
|
208235
|
+
obsSetsColumnNameMappingReversed,
|
208236
|
+
sampleSetsColumnNameMapping,
|
208237
|
+
sampleSetsColumnNameMappingReversed,
|
208238
|
+
sampleSetSelection,
|
208239
|
+
obsSetSelection,
|
208240
|
+
obsSetColor,
|
208241
|
+
sampleSetColor,
|
208242
|
+
data: obsSetStats,
|
208243
|
+
onBarSelect
|
208244
|
+
}
|
208245
|
+
) : /* @__PURE__ */ jsxRuntimeExports.jsxs("span", { children: [
|
208246
|
+
"Select at least one ",
|
208247
|
+
obsType,
|
208248
|
+
" set."
|
208249
|
+
] }) })
|
208250
|
+
}
|
208251
|
+
);
|
208252
|
+
}
|
208253
|
+
function FeatureSetEnrichmentBarPlot(props) {
|
208254
|
+
const {
|
208255
|
+
data: data2,
|
208256
|
+
theme,
|
208257
|
+
width: width2,
|
208258
|
+
height: height2,
|
208259
|
+
marginRight = 200,
|
208260
|
+
marginBottom = 120,
|
208261
|
+
keyLength = 36,
|
208262
|
+
featureType,
|
208263
|
+
onBarSelect,
|
208264
|
+
obsSetsColumnNameMappingReversed,
|
208265
|
+
sampleSetsColumnNameMappingReversed,
|
208266
|
+
sampleSetSelection,
|
208267
|
+
obsSetSelection,
|
208268
|
+
obsSetColor,
|
208269
|
+
sampleSetColor,
|
208270
|
+
pValueThreshold
|
208271
|
+
} = props;
|
208272
|
+
const [obsSetColorScale, sampleSetColorScale] = useMemo(() => [
|
208273
|
+
getColorScale(obsSetSelection, obsSetColor, theme),
|
208274
|
+
getColorScale(sampleSetSelection, sampleSetColor, theme)
|
208275
|
+
], [obsSetSelection, sampleSetSelection, sampleSetColor, obsSetColor, theme]);
|
208276
|
+
const computedData = useMemo(() => {
|
208277
|
+
if (Array.isArray(data2)) {
|
208278
|
+
let result = [];
|
208279
|
+
data2.forEach((comparisonObject) => {
|
208280
|
+
const { df, metadata: metadata2 } = comparisonObject;
|
208281
|
+
const coordinationValues = metadata2 == null ? void 0 : metadata2.coordination_values;
|
208282
|
+
const rawObsSetPath = coordinationValues.obsSetFilter ? coordinationValues.obsSetFilter[0] : coordinationValues.obsSetSelection[0];
|
208283
|
+
const obsSetPath = [...rawObsSetPath];
|
208284
|
+
obsSetPath[0] = obsSetsColumnNameMappingReversed[rawObsSetPath[0]];
|
208285
|
+
const color2 = obsSetColorScale(obsSetPath);
|
208286
|
+
df.featureSetName.forEach((featureSetName, i2) => {
|
208287
|
+
const key2 = v4$1();
|
208288
|
+
result.push({
|
208289
|
+
key: key2,
|
208290
|
+
name: featureSetName,
|
208291
|
+
term: df.featureSetTerm[i2],
|
208292
|
+
color: color2,
|
208293
|
+
obsSetPath,
|
208294
|
+
obsSetPaths: [obsSetPath],
|
208295
|
+
obsSetNameToPval: { [obsSetPath.at(-1)]: df.featureSetSignificance[i2] },
|
208296
|
+
keyName: `${key2}${featureSetName}`,
|
208297
|
+
featureSetSignificance: df.featureSetSignificance[i2],
|
208298
|
+
minusLog10p: -Math.log10(df.featureSetSignificance[i2])
|
208299
|
+
// Color based on obsSet
|
208300
|
+
});
|
208301
|
+
});
|
208302
|
+
});
|
208303
|
+
result = result.map((d) => ({
|
208304
|
+
...d,
|
208305
|
+
minusLog10p: Math.min(50, d.minusLog10p)
|
208306
|
+
// Clamp infinite values at 50
|
208307
|
+
})).filter((d) => d.featureSetSignificance <= pValueThreshold).toSorted((a2, b2) => a2.featureSetSignificance - b2.featureSetSignificance).reduce((a2, h2) => {
|
208308
|
+
const match2 = a2.find((d) => d.name === h2.name);
|
208309
|
+
if (match2) {
|
208310
|
+
match2.obsSetPaths.push(h2.obsSetPath);
|
208311
|
+
match2.obsSetNameToPval[h2.obsSetPath.at(-1)] = h2.featureSetSignificance;
|
208312
|
+
return a2;
|
208313
|
+
}
|
208314
|
+
return [...a2, h2];
|
208315
|
+
}, []);
|
208316
|
+
const MAX_ROWS = 25;
|
208317
|
+
result = result.slice(0, MAX_ROWS);
|
208318
|
+
return result;
|
208319
|
+
}
|
208320
|
+
return null;
|
208321
|
+
}, [
|
208322
|
+
data2,
|
208323
|
+
sampleSetSelection,
|
208324
|
+
obsSetsColumnNameMappingReversed,
|
208325
|
+
sampleSetsColumnNameMappingReversed,
|
208326
|
+
obsSetSelection,
|
208327
|
+
obsSetColorScale,
|
208328
|
+
sampleSetColorScale,
|
208329
|
+
pValueThreshold
|
208330
|
+
]);
|
208331
|
+
const keys3 = computedData.map((d) => d.keyName);
|
208332
|
+
const colorScale2 = {
|
208333
|
+
// Manually set the color scale so that Vega-Lite does
|
208334
|
+
// not choose the colors automatically.
|
208335
|
+
domain: computedData.map((d) => d.key),
|
208336
|
+
range: computedData.map((d) => d.color)
|
208337
|
+
};
|
208338
|
+
const captializedFeatureType = capitalize$2(featureType);
|
208339
|
+
const spec = {
|
208340
|
+
mark: { type: "bar", stroke: "black", cursor: "pointer" },
|
208341
|
+
params: [
|
208342
|
+
{
|
208343
|
+
name: "bar_select",
|
208344
|
+
select: {
|
208345
|
+
type: "point",
|
208346
|
+
on: "click[event.shiftKey === false]",
|
208347
|
+
fields: ["name"],
|
208348
|
+
empty: "none"
|
208349
|
+
}
|
208350
|
+
},
|
208351
|
+
{
|
208352
|
+
name: "shift_bar_select",
|
208353
|
+
select: {
|
208354
|
+
type: "point",
|
208355
|
+
on: "click[event.shiftKey]",
|
208356
|
+
fields: ["name"],
|
208357
|
+
empty: "none"
|
208358
|
+
}
|
208359
|
+
}
|
208360
|
+
],
|
208361
|
+
encoding: {
|
208362
|
+
y: {
|
208363
|
+
field: "keyName",
|
208364
|
+
type: "nominal",
|
208365
|
+
axis: { labelExpr: `substring(datum.label, ${keyLength})` },
|
208366
|
+
title: `${captializedFeatureType} Set`,
|
208367
|
+
sort: keys3
|
208368
|
+
},
|
208369
|
+
x: {
|
208370
|
+
field: "minusLog10p",
|
208371
|
+
type: "quantitative",
|
208372
|
+
title: "- log10 p-value"
|
208373
|
+
},
|
208374
|
+
color: {
|
208375
|
+
field: "key",
|
208376
|
+
type: "nominal",
|
208377
|
+
scale: colorScale2,
|
208378
|
+
legend: null
|
208379
|
+
},
|
208380
|
+
/*
|
208381
|
+
fillOpacity: {
|
208382
|
+
field: 'isCredibleEffect',
|
208383
|
+
type: 'nominal',
|
208384
|
+
scale: opacityScale,
|
208385
|
+
},
|
208386
|
+
strokeWidth: {
|
208387
|
+
field: 'isReferenceSet',
|
208388
|
+
type: 'nominal',
|
208389
|
+
scale: strokeWidthScale,
|
208390
|
+
},
|
208391
|
+
*/
|
208392
|
+
tooltip: {
|
208393
|
+
field: "featureSetSignificance",
|
208394
|
+
type: "quantitative"
|
208395
|
+
}
|
208396
|
+
},
|
208397
|
+
// TODO: for width, also subtract length of longest y-axis set name label.
|
208398
|
+
width: clamp$5(width2 - marginRight, 10, Infinity),
|
208399
|
+
height: clamp$5(height2 - marginBottom, 10, Infinity),
|
208400
|
+
config: VEGA_THEMES[theme]
|
208401
|
+
};
|
208402
|
+
const handleSignal = (name2, value2) => {
|
208403
|
+
if (name2 === "bar_select") {
|
208404
|
+
onBarSelect(value2.obsSetPath);
|
208405
|
+
} else if (name2 === "shift_bar_select") {
|
208406
|
+
onBarSelect(value2.obsSetPath, true);
|
208407
|
+
}
|
208408
|
+
};
|
208409
|
+
const signalListeners = { bar_select: handleSignal, shift_bar_select: handleSignal };
|
208410
|
+
const getTooltipText = useCallback((item) => ({
|
208411
|
+
[`${captializedFeatureType} Set`]: item.datum.name,
|
208412
|
+
"Ontology Term": item.datum.term,
|
208413
|
+
...Object.fromEntries(
|
208414
|
+
Object.entries(item.datum.obsSetNameToPval).map(([cellSetName, pVal]) => [
|
208415
|
+
`p-value for ${cellSetName}`,
|
208416
|
+
pVal
|
208417
|
+
])
|
208418
|
+
)
|
208419
|
+
}), [captializedFeatureType]);
|
208420
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(
|
208421
|
+
VegaPlot,
|
208422
|
+
{
|
208423
|
+
data: computedData,
|
208424
|
+
spec,
|
208425
|
+
signalListeners,
|
208426
|
+
getTooltipText
|
208427
|
+
}
|
208428
|
+
);
|
208429
|
+
}
|
208430
|
+
function FeatureSetEnrichmentBarPlotSubscriber(props) {
|
208431
|
+
const {
|
208432
|
+
coordinationScopes,
|
208433
|
+
removeGridComponent,
|
208434
|
+
theme,
|
208435
|
+
helpText = ViewHelpMapping.FEATURE_SET_ENRICHMENT_BAR_PLOT
|
208436
|
+
} = props;
|
208437
|
+
const classes = useStyles$1();
|
208438
|
+
const loaders = useLoaders();
|
208439
|
+
useAsyncFunction(AsyncFunctionType.TRANSFORM_FEATURE);
|
208440
|
+
const [{
|
208441
|
+
dataset,
|
208442
|
+
obsType,
|
208443
|
+
sampleType,
|
208444
|
+
featureType,
|
208445
|
+
featureValueType,
|
208446
|
+
obsFilter: cellFilter,
|
208447
|
+
obsHighlight: cellHighlight,
|
208448
|
+
obsSetSelection,
|
208449
|
+
obsSetColor,
|
208450
|
+
obsColorEncoding: cellColorEncoding,
|
208451
|
+
additionalObsSets: additionalCellSets,
|
208452
|
+
featurePointSignificanceThreshold,
|
208453
|
+
featurePointFoldChangeThreshold,
|
208454
|
+
featureLabelSignificanceThreshold,
|
208455
|
+
featureLabelFoldChangeThreshold,
|
208456
|
+
featureValueTransform,
|
208457
|
+
featureValueTransformCoefficient,
|
208458
|
+
gatingFeatureSelectionX,
|
208459
|
+
gatingFeatureSelectionY,
|
208460
|
+
featureSelection,
|
208461
|
+
sampleSetSelection,
|
208462
|
+
sampleSetColor
|
208463
|
+
}, {
|
208464
|
+
setObsFilter: setCellFilter,
|
208465
|
+
setObsSetSelection,
|
208466
|
+
setObsHighlight: setCellHighlight,
|
208467
|
+
setObsSetColor: setCellSetColor,
|
208468
|
+
setObsColorEncoding: setCellColorEncoding,
|
208469
|
+
setAdditionalObsSets: setAdditionalCellSets,
|
208470
|
+
setFeaturePointSignificanceThreshold,
|
208471
|
+
setFeaturePointFoldChangeThreshold,
|
208472
|
+
setFeatureLabelSignificanceThreshold,
|
208473
|
+
setFeatureLabelFoldChangeThreshold,
|
208474
|
+
setFeatureValueTransform,
|
208475
|
+
setFeatureValueTransformCoefficient,
|
208476
|
+
setGatingFeatureSelectionX,
|
208477
|
+
setGatingFeatureSelectionY,
|
208478
|
+
setFeatureSelection,
|
208479
|
+
setSampleSetSelection,
|
208480
|
+
setSampleSetColor
|
208481
|
+
}] = useCoordination(
|
208482
|
+
COMPONENT_COORDINATION_TYPES[ViewType$1.FEATURE_SET_ENRICHMENT_BAR_PLOT],
|
208483
|
+
coordinationScopes
|
208484
|
+
);
|
208485
|
+
const [width2, height2, containerRef] = useGridItemSize();
|
208486
|
+
const obsSetsLoader = useMatchingLoader(
|
208487
|
+
loaders,
|
208488
|
+
dataset,
|
208489
|
+
DataType$2.OBS_SETS,
|
208490
|
+
{ obsType }
|
208491
|
+
);
|
208492
|
+
const sampleSetsLoader = useMatchingLoader(
|
208493
|
+
loaders,
|
208494
|
+
dataset,
|
208495
|
+
DataType$2.SAMPLE_SETS,
|
208496
|
+
{ sampleType }
|
208497
|
+
);
|
208498
|
+
const obsSetsColumnNameMapping = useColumnNameMapping(obsSetsLoader);
|
208499
|
+
const obsSetsColumnNameMappingReversed = useColumnNameMapping(obsSetsLoader, true);
|
208500
|
+
const sampleSetsColumnNameMapping = useColumnNameMapping(sampleSetsLoader);
|
208501
|
+
const sampleSetsColumnNameMappingReversed = useColumnNameMapping(sampleSetsLoader, true);
|
208502
|
+
const rawSampleSetSelection = useRawSetPaths(sampleSetsColumnNameMapping, sampleSetSelection);
|
208503
|
+
const rawObsSetSelection = useRawSetPaths(obsSetsColumnNameMapping, obsSetSelection);
|
208504
|
+
const [{ featureSetStats }, featureSetStatsStatus] = useFeatureSetStatsData(
|
208505
|
+
loaders,
|
208506
|
+
dataset,
|
208507
|
+
false,
|
208508
|
+
{ obsType, featureType, sampleType },
|
208509
|
+
// These volcanoOptions are passed to ObsSetStatsAnndataLoader.loadMulti():
|
208510
|
+
{ sampleSetSelection: rawSampleSetSelection, obsSetSelection: rawObsSetSelection }
|
208511
|
+
);
|
208512
|
+
const isReady = useReady([
|
208513
|
+
featureSetStatsStatus
|
208514
|
+
]);
|
208515
|
+
const onBarSelect = useCallback(async (featureSetName, featureSetTerm, isShiftDown = false) => {
|
208516
|
+
}, [setFeatureSelection]);
|
208517
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(
|
208518
|
+
TitleInfo,
|
208519
|
+
{
|
208520
|
+
title: `${capitalize$2(featureType)} Set Enrichment Plot`,
|
208521
|
+
removeGridComponent,
|
208522
|
+
theme,
|
208523
|
+
isReady,
|
208524
|
+
helpText,
|
208525
|
+
children: /* @__PURE__ */ jsxRuntimeExports.jsx("div", { ref: containerRef, className: classes.vegaContainer, children: featureSetStats ? /* @__PURE__ */ jsxRuntimeExports.jsx(
|
208526
|
+
FeatureSetEnrichmentBarPlot,
|
208527
|
+
{
|
208528
|
+
theme,
|
208529
|
+
width: width2,
|
208530
|
+
height: height2,
|
208531
|
+
obsType,
|
208532
|
+
featureType,
|
208533
|
+
obsSetsColumnNameMapping,
|
208534
|
+
obsSetsColumnNameMappingReversed,
|
208535
|
+
sampleSetsColumnNameMapping,
|
208536
|
+
sampleSetsColumnNameMappingReversed,
|
208537
|
+
sampleSetSelection,
|
208538
|
+
obsSetSelection,
|
208539
|
+
obsSetColor,
|
208540
|
+
sampleSetColor,
|
208541
|
+
data: featureSetStats,
|
208542
|
+
onBarSelect,
|
208543
|
+
pValueThreshold: 0.01
|
208544
|
+
}
|
208545
|
+
) : /* @__PURE__ */ jsxRuntimeExports.jsxs("span", { children: [
|
208546
|
+
"Select at least one ",
|
208547
|
+
obsType,
|
208548
|
+
" set."
|
208549
|
+
] }) })
|
208550
|
+
}
|
208551
|
+
);
|
208552
|
+
}
|
207552
208553
|
export {
|
207553
208554
|
BaseDecoder as B,
|
207554
208555
|
CellSetExpressionPlotSubscriber as C,
|
@@ -207556,10 +208557,13 @@ export {
|
|
207556
208557
|
ExpressionHistogramSubscriber as E,
|
207557
208558
|
FeatureBarPlotSubscriber as F,
|
207558
208559
|
TreemapSubscriber as T,
|
208560
|
+
VolcanoPlotSubscriber as V,
|
207559
208561
|
CellSetSizesPlotSubscriber as a,
|
207560
|
-
|
207561
|
-
|
207562
|
-
|
207563
|
-
|
207564
|
-
|
208562
|
+
CellSetCompositionBarPlotSubscriber as b,
|
208563
|
+
FeatureSetEnrichmentBarPlotSubscriber as c,
|
208564
|
+
CellSetSizesPlot as d,
|
208565
|
+
CellSetExpressionPlot as e,
|
208566
|
+
ExpressionHistogram as f,
|
208567
|
+
getDefaultExportFromCjs as g,
|
208568
|
+
DotPlot as h
|
207565
208569
|
};
|