@vitessce/scatterplot-embedding 3.4.14 → 3.5.1
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-8db7a1fd.js → deflate-aa8592bc.js} +1 -1
- package/dist/{index-b7514fa1.js → index-b29153a1.js} +48 -37
- package/dist/index.js +1 -1
- package/dist/{jpeg-e3c6cd06.js → jpeg-fb8ccf5b.js} +1 -1
- package/dist/{lerc-d255ce3d.js → lerc-6a5274b2.js} +1 -1
- package/dist/{lzw-e7ee88d7.js → lzw-b0644528.js} +1 -1
- package/dist/{packbits-b69fb1e8.js → packbits-54f0a5dc.js} +1 -1
- package/dist/{raw-829ad888.js → raw-d4deb41a.js} +1 -1
- package/dist/{webimage-91330202.js → webimage-75b55168.js} +1 -1
- package/dist-tsc/EmbeddingScatterplotSubscriber.d.ts.map +1 -1
- package/dist-tsc/EmbeddingScatterplotSubscriber.js +2 -2
- package/package.json +8 -8
- package/src/EmbeddingScatterplotSubscriber.js +6 -1
|
@@ -11010,7 +11010,8 @@ const ViewType$1 = {
|
|
|
11010
11010
|
OBS_SET_FEATURE_VALUE_DISTRIBUTION: "obsSetFeatureValueDistribution",
|
|
11011
11011
|
FEATURE_VALUE_HISTOGRAM: "featureValueHistogram",
|
|
11012
11012
|
DOT_PLOT: "dotPlot",
|
|
11013
|
-
FEATURE_BAR_PLOT: "featureBarPlot"
|
|
11013
|
+
FEATURE_BAR_PLOT: "featureBarPlot",
|
|
11014
|
+
BIOMARKER_SELECT: "biomarkerSelect"
|
|
11014
11015
|
};
|
|
11015
11016
|
const DataType$2 = {
|
|
11016
11017
|
OBS_LABELS: "obsLabels",
|
|
@@ -11705,6 +11706,11 @@ const COMPONENT_COORDINATION_TYPES = {
|
|
|
11705
11706
|
CoordinationType$1.OBS_SET_COLOR,
|
|
11706
11707
|
CoordinationType$1.OBS_COLOR_ENCODING,
|
|
11707
11708
|
CoordinationType$1.ADDITIONAL_OBS_SETS
|
|
11709
|
+
],
|
|
11710
|
+
[ViewType$1.BIOMARKER_SELECT]: [
|
|
11711
|
+
CoordinationType$1.FEATURE_SELECTION,
|
|
11712
|
+
CoordinationType$1.SAMPLE_SET_SELECTION
|
|
11713
|
+
// TODO: create coordination types for internal state of the biomarker selection view?
|
|
11708
11714
|
]
|
|
11709
11715
|
};
|
|
11710
11716
|
const ViewType = {
|
|
@@ -89694,7 +89700,7 @@ keysShim.shim = function shimObjectKeys() {
|
|
|
89694
89700
|
return Object.keys || keysShim;
|
|
89695
89701
|
};
|
|
89696
89702
|
var objectKeys$1 = keysShim;
|
|
89697
|
-
var shams$
|
|
89703
|
+
var shams$1 = function hasSymbols() {
|
|
89698
89704
|
if (typeof Symbol !== "function" || typeof Object.getOwnPropertySymbols !== "function") {
|
|
89699
89705
|
return false;
|
|
89700
89706
|
}
|
|
@@ -89739,9 +89745,9 @@ var shams$2 = function hasSymbols() {
|
|
|
89739
89745
|
}
|
|
89740
89746
|
return true;
|
|
89741
89747
|
};
|
|
89742
|
-
var hasSymbols$
|
|
89743
|
-
var shams
|
|
89744
|
-
return hasSymbols$
|
|
89748
|
+
var hasSymbols$3 = shams$1;
|
|
89749
|
+
var shams = function hasToStringTagShams() {
|
|
89750
|
+
return hasSymbols$3() && !!Symbol.toStringTag;
|
|
89745
89751
|
};
|
|
89746
89752
|
var esErrors = Error;
|
|
89747
89753
|
var _eval = EvalError;
|
|
@@ -89751,8 +89757,8 @@ var syntax = SyntaxError;
|
|
|
89751
89757
|
var type = TypeError;
|
|
89752
89758
|
var uri = URIError;
|
|
89753
89759
|
var origSymbol = typeof Symbol !== "undefined" && Symbol;
|
|
89754
|
-
var hasSymbolSham = shams$
|
|
89755
|
-
var hasSymbols$
|
|
89760
|
+
var hasSymbolSham = shams$1;
|
|
89761
|
+
var hasSymbols$2 = function hasNativeSymbols() {
|
|
89756
89762
|
if (typeof origSymbol !== "function") {
|
|
89757
89763
|
return false;
|
|
89758
89764
|
}
|
|
@@ -89768,11 +89774,12 @@ var hasSymbols$3 = function hasNativeSymbols() {
|
|
|
89768
89774
|
return hasSymbolSham();
|
|
89769
89775
|
};
|
|
89770
89776
|
var test = {
|
|
89777
|
+
__proto__: null,
|
|
89771
89778
|
foo: {}
|
|
89772
89779
|
};
|
|
89773
89780
|
var $Object$1 = Object;
|
|
89774
89781
|
var hasProto$1 = function hasProto() {
|
|
89775
|
-
return { __proto__: test }.foo === test.foo && !(
|
|
89782
|
+
return { __proto__: test }.foo === test.foo && !(test instanceof $Object$1);
|
|
89776
89783
|
};
|
|
89777
89784
|
var ERROR_MESSAGE = "Function.prototype.bind called on incompatible ";
|
|
89778
89785
|
var toStr$2 = Object.prototype.toString;
|
|
@@ -89887,7 +89894,7 @@ var ThrowTypeError = $gOPD$2 ? function() {
|
|
|
89887
89894
|
}
|
|
89888
89895
|
}
|
|
89889
89896
|
}() : throwTypeError;
|
|
89890
|
-
var hasSymbols$
|
|
89897
|
+
var hasSymbols$1 = hasSymbols$2();
|
|
89891
89898
|
var hasProto2 = hasProto$1();
|
|
89892
89899
|
var getProto$1 = Object.getPrototypeOf || (hasProto2 ? function(x2) {
|
|
89893
89900
|
return x2.__proto__;
|
|
@@ -89899,7 +89906,7 @@ var INTRINSICS = {
|
|
|
89899
89906
|
"%AggregateError%": typeof AggregateError === "undefined" ? undefined$1 : AggregateError,
|
|
89900
89907
|
"%Array%": Array,
|
|
89901
89908
|
"%ArrayBuffer%": typeof ArrayBuffer === "undefined" ? undefined$1 : ArrayBuffer,
|
|
89902
|
-
"%ArrayIteratorPrototype%": hasSymbols$
|
|
89909
|
+
"%ArrayIteratorPrototype%": hasSymbols$1 && getProto$1 ? getProto$1([][Symbol.iterator]()) : undefined$1,
|
|
89903
89910
|
"%AsyncFromSyncIteratorPrototype%": undefined$1,
|
|
89904
89911
|
"%AsyncFunction%": needsEval,
|
|
89905
89912
|
"%AsyncGenerator%": needsEval,
|
|
@@ -89930,10 +89937,10 @@ var INTRINSICS = {
|
|
|
89930
89937
|
"%Int32Array%": typeof Int32Array === "undefined" ? undefined$1 : Int32Array,
|
|
89931
89938
|
"%isFinite%": isFinite,
|
|
89932
89939
|
"%isNaN%": isNaN,
|
|
89933
|
-
"%IteratorPrototype%": hasSymbols$
|
|
89940
|
+
"%IteratorPrototype%": hasSymbols$1 && getProto$1 ? getProto$1(getProto$1([][Symbol.iterator]())) : undefined$1,
|
|
89934
89941
|
"%JSON%": typeof JSON === "object" ? JSON : undefined$1,
|
|
89935
89942
|
"%Map%": typeof Map === "undefined" ? undefined$1 : Map,
|
|
89936
|
-
"%MapIteratorPrototype%": typeof Map === "undefined" || !hasSymbols$
|
|
89943
|
+
"%MapIteratorPrototype%": typeof Map === "undefined" || !hasSymbols$1 || !getProto$1 ? undefined$1 : getProto$1((/* @__PURE__ */ new Map())[Symbol.iterator]()),
|
|
89937
89944
|
"%Math%": Math,
|
|
89938
89945
|
"%Number%": Number,
|
|
89939
89946
|
"%Object%": Object,
|
|
@@ -89946,11 +89953,11 @@ var INTRINSICS = {
|
|
|
89946
89953
|
"%Reflect%": typeof Reflect === "undefined" ? undefined$1 : Reflect,
|
|
89947
89954
|
"%RegExp%": RegExp,
|
|
89948
89955
|
"%Set%": typeof Set === "undefined" ? undefined$1 : Set,
|
|
89949
|
-
"%SetIteratorPrototype%": typeof Set === "undefined" || !hasSymbols$
|
|
89956
|
+
"%SetIteratorPrototype%": typeof Set === "undefined" || !hasSymbols$1 || !getProto$1 ? undefined$1 : getProto$1((/* @__PURE__ */ new Set())[Symbol.iterator]()),
|
|
89950
89957
|
"%SharedArrayBuffer%": typeof SharedArrayBuffer === "undefined" ? undefined$1 : SharedArrayBuffer,
|
|
89951
89958
|
"%String%": String,
|
|
89952
|
-
"%StringIteratorPrototype%": hasSymbols$
|
|
89953
|
-
"%Symbol%": hasSymbols$
|
|
89959
|
+
"%StringIteratorPrototype%": hasSymbols$1 && getProto$1 ? getProto$1(""[Symbol.iterator]()) : undefined$1,
|
|
89960
|
+
"%Symbol%": hasSymbols$1 ? Symbol : undefined$1,
|
|
89954
89961
|
"%SyntaxError%": $SyntaxError$1,
|
|
89955
89962
|
"%ThrowTypeError%": ThrowTypeError,
|
|
89956
89963
|
"%TypedArray%": TypedArray,
|
|
@@ -90319,7 +90326,7 @@ var callBound$2 = function callBoundIntrinsic(name2, allowMissing) {
|
|
|
90319
90326
|
}
|
|
90320
90327
|
return intrinsic;
|
|
90321
90328
|
};
|
|
90322
|
-
var hasToStringTag$2 = shams
|
|
90329
|
+
var hasToStringTag$2 = shams();
|
|
90323
90330
|
var callBound$1 = callBound$2;
|
|
90324
90331
|
var $toString$1 = callBound$1("Object.prototype.toString");
|
|
90325
90332
|
var isStandardArguments = function isArguments2(value) {
|
|
@@ -90364,7 +90371,7 @@ hasPropertyDescriptors2.hasArrayLengthDefineBug = function hasArrayLengthDefineB
|
|
|
90364
90371
|
};
|
|
90365
90372
|
var hasPropertyDescriptors_1 = hasPropertyDescriptors2;
|
|
90366
90373
|
var keys$1 = objectKeys$1;
|
|
90367
|
-
var
|
|
90374
|
+
var hasSymbols2 = typeof Symbol === "function" && typeof Symbol("foo") === "symbol";
|
|
90368
90375
|
var toStr$1 = Object.prototype.toString;
|
|
90369
90376
|
var concat = Array.prototype.concat;
|
|
90370
90377
|
var defineDataProperty2 = defineDataProperty$1;
|
|
@@ -90391,7 +90398,7 @@ var defineProperty$3 = function(object2, name2, value, predicate) {
|
|
|
90391
90398
|
var defineProperties = function(object2, map2) {
|
|
90392
90399
|
var predicates = arguments.length > 2 ? arguments[2] : {};
|
|
90393
90400
|
var props = keys$1(map2);
|
|
90394
|
-
if (
|
|
90401
|
+
if (hasSymbols2) {
|
|
90395
90402
|
props = concat.call(props, Object.getOwnPropertySymbols(map2));
|
|
90396
90403
|
}
|
|
90397
90404
|
for (var i2 = 0; i2 < props.length; i2 += 1) {
|
|
@@ -90442,10 +90449,6 @@ define$4(polyfill$1, {
|
|
|
90442
90449
|
shim: shim$2
|
|
90443
90450
|
});
|
|
90444
90451
|
var objectIs = polyfill$1;
|
|
90445
|
-
var hasSymbols2 = shams$2;
|
|
90446
|
-
var shams = function hasToStringTagShams2() {
|
|
90447
|
-
return hasSymbols2() && !!Symbol.toStringTag;
|
|
90448
|
-
};
|
|
90449
90452
|
var callBound = callBound$2;
|
|
90450
90453
|
var hasToStringTag$1 = shams();
|
|
90451
90454
|
var has$3;
|
|
@@ -90652,7 +90655,7 @@ var tryDateObject = function tryDateGetDayCall(value) {
|
|
|
90652
90655
|
};
|
|
90653
90656
|
var toStr = Object.prototype.toString;
|
|
90654
90657
|
var dateClass = "[object Date]";
|
|
90655
|
-
var hasToStringTag = shams
|
|
90658
|
+
var hasToStringTag = shams();
|
|
90656
90659
|
var isDateObject = function isDateObject2(value) {
|
|
90657
90660
|
if (typeof value !== "object" || value === null) {
|
|
90658
90661
|
return false;
|
|
@@ -123972,16 +123975,16 @@ function addDecoder(cases, importFn) {
|
|
|
123972
123975
|
}
|
|
123973
123976
|
cases.forEach((c2) => registry$1.set(c2, importFn));
|
|
123974
123977
|
}
|
|
123975
|
-
addDecoder([void 0, 1], () => import("./raw-
|
|
123976
|
-
addDecoder(5, () => import("./lzw-
|
|
123978
|
+
addDecoder([void 0, 1], () => import("./raw-d4deb41a.js").then((m2) => m2.default));
|
|
123979
|
+
addDecoder(5, () => import("./lzw-b0644528.js").then((m2) => m2.default));
|
|
123977
123980
|
addDecoder(6, () => {
|
|
123978
123981
|
throw new Error("old style JPEG compression is not supported.");
|
|
123979
123982
|
});
|
|
123980
|
-
addDecoder(7, () => import("./jpeg-
|
|
123981
|
-
addDecoder([8, 32946], () => import("./deflate-
|
|
123982
|
-
addDecoder(32773, () => import("./packbits-
|
|
123983
|
-
addDecoder(34887, () => import("./lerc-
|
|
123984
|
-
addDecoder(50001, () => import("./webimage-
|
|
123983
|
+
addDecoder(7, () => import("./jpeg-fb8ccf5b.js").then((m2) => m2.default));
|
|
123984
|
+
addDecoder([8, 32946], () => import("./deflate-aa8592bc.js").then((m2) => m2.default));
|
|
123985
|
+
addDecoder(32773, () => import("./packbits-54f0a5dc.js").then((m2) => m2.default));
|
|
123986
|
+
addDecoder(34887, () => import("./lerc-6a5274b2.js").then((m2) => m2.default));
|
|
123987
|
+
addDecoder(50001, () => import("./webimage-75b55168.js").then((m2) => m2.default));
|
|
123985
123988
|
function decodeRowAcc(row, stride) {
|
|
123986
123989
|
let length2 = row.length - stride;
|
|
123987
123990
|
let offset5 = 0;
|
|
@@ -144817,6 +144820,7 @@ const CELLS_LAYER_ID = "scatterplot";
|
|
|
144817
144820
|
const LABEL_FONT_FAMILY = "-apple-system, 'Helvetica Neue', Arial, sans-serif";
|
|
144818
144821
|
const NUM_FORCE_SIMULATION_TICKS = 100;
|
|
144819
144822
|
const LABEL_UPDATE_ZOOM_DELTA = 0.25;
|
|
144823
|
+
const POINT_LAYER_Z_INDEX = 0;
|
|
144820
144824
|
const makeDefaultGetCellColors = (cellColors, obsIndex, theme) => (object2, { index: index2 }) => {
|
|
144821
144825
|
const [r2, g2, b, a2] = cellColors && obsIndex && cellColors.get(obsIndex[index2]) || getDefaultColor(theme);
|
|
144822
144826
|
return [r2, g2, b, 255 * (a2 || 1)];
|
|
@@ -144834,7 +144838,7 @@ const makeFlippedGetObsCoords = (obsEmbedding) => (i2) => [
|
|
|
144834
144838
|
const getPosition = (object2, { index: index2, data, target }) => {
|
|
144835
144839
|
target[0] = data.src.obsEmbedding.data[0][index2];
|
|
144836
144840
|
target[1] = -data.src.obsEmbedding.data[1][index2];
|
|
144837
|
-
target[2] =
|
|
144841
|
+
target[2] = POINT_LAYER_Z_INDEX;
|
|
144838
144842
|
return target;
|
|
144839
144843
|
};
|
|
144840
144844
|
const contourGetWeight = (object2, { index: index2, data }) => data.src.featureValues[index2];
|
|
@@ -144844,7 +144848,6 @@ const contourGetPosition = (object2, { index: index2, data, target }) => {
|
|
|
144844
144848
|
target[2] = 0;
|
|
144845
144849
|
return target;
|
|
144846
144850
|
};
|
|
144847
|
-
const contourGetPolygonOffset = () => [0, 20];
|
|
144848
144851
|
class Scatterplot extends AbstractSpatialOrScatterplot {
|
|
144849
144852
|
constructor(props) {
|
|
144850
144853
|
super(props);
|
|
@@ -144884,7 +144887,6 @@ class Scatterplot extends AbstractSpatialOrScatterplot {
|
|
|
144884
144887
|
data: deckData,
|
|
144885
144888
|
getWeight: contourGetWeight,
|
|
144886
144889
|
getPosition: contourGetPosition,
|
|
144887
|
-
getPolygonOffset: contourGetPolygonOffset,
|
|
144888
144890
|
contours: contourThresholds.map((threshold, i2) => ({
|
|
144889
144891
|
threshold: contoursFilled ? [threshold, threshold[i2 + 1] || Infinity] : threshold,
|
|
144890
144892
|
// TODO: should the opacity steps be uniform? Should align with human perception.
|
|
@@ -144895,7 +144897,10 @@ class Scatterplot extends AbstractSpatialOrScatterplot {
|
|
|
144895
144897
|
// a
|
|
144896
144898
|
contoursFilled ? (i2 + 0.5) / contourThresholds.length * 255 : (i2 + 1) / contourThresholds.length * 255
|
|
144897
144899
|
],
|
|
144898
|
-
strokeWidth: 2
|
|
144900
|
+
strokeWidth: 2,
|
|
144901
|
+
// We need to specify a greater z-index so that the contour layers
|
|
144902
|
+
// will render on top of the point layer.
|
|
144903
|
+
zIndex: POINT_LAYER_Z_INDEX + 1 + i2
|
|
144899
144904
|
})),
|
|
144900
144905
|
aggregation: "MEAN",
|
|
144901
144906
|
gpuAggregation: true,
|
|
@@ -148009,7 +148014,7 @@ const rectHeight = 8;
|
|
|
148009
148014
|
const rectMarginY = 2;
|
|
148010
148015
|
const rectMarginX = 2;
|
|
148011
148016
|
function Legend(props) {
|
|
148012
|
-
const { visible: visibleProp, positionRelative = false, highContrast = false, obsType, featureValueType, considerSelections = true, obsColorEncoding, featureSelection, featureLabelsMap, featureValueColormap, featureValueColormapRange, spatialChannelColor, spatialLayerColor, obsSetSelection, obsSetColor, extent: extent2, width = 100, height = 36, theme, showObsLabel = false, pointsVisible = true, contoursVisible = false, contoursFilled, contourPercentiles, contourThresholds } = props;
|
|
148017
|
+
const { visible: visibleProp, positionRelative = false, highContrast = false, obsType, featureValueType, considerSelections = true, obsColorEncoding, featureSelection, featureLabelsMap, featureValueColormap, featureValueColormapRange, spatialChannelColor, spatialLayerColor, obsSetSelection, obsSetColor, extent: extent2, missing, width = 100, height = 36, theme, showObsLabel = false, pointsVisible = true, contoursVisible = false, contoursFilled, contourPercentiles, contourThresholds } = props;
|
|
148013
148018
|
const svgRef = useRef();
|
|
148014
148019
|
const classes = useStyles();
|
|
148015
148020
|
const isDarkTheme = theme === "dark";
|
|
@@ -148093,7 +148098,8 @@ function Legend(props) {
|
|
|
148093
148098
|
});
|
|
148094
148099
|
});
|
|
148095
148100
|
}
|
|
148096
|
-
const
|
|
148101
|
+
const featureSelectionLabelRaw = featureSelection && featureSelection.length >= 1 && !isStaticColor ? (featureLabelsMap == null ? void 0 : featureLabelsMap.get(featureSelection[0])) || featureSelection[0] : null;
|
|
148102
|
+
const featureSelectionLabel = missing ? `${featureSelectionLabelRaw} (${Math.round(missing * 100)}% NaN)` : featureSelectionLabelRaw;
|
|
148097
148103
|
const obsLabel = capitalize$1(obsType);
|
|
148098
148104
|
const featureLabel = considerSelections ? featureSelectionLabel || capitalize$1(featureValueType) : capitalize$1(featureValueType);
|
|
148099
148105
|
const mainLabel = showObsLabel ? obsLabel : featureLabel;
|
|
@@ -148488,7 +148494,11 @@ function EmbeddingScatterplotSubscriber(props) {
|
|
|
148488
148494
|
const getCellIsSelected = useCallback((object2, { index: index2 }) => (cellSelectionSet || /* @__PURE__ */ new Set([])).has(obsEmbeddingIndex[index2]) ? 1 : 0, [cellSelectionSet, obsEmbeddingIndex]);
|
|
148489
148495
|
const cellRadius = cellRadiusMode === "manual" ? cellRadiusFixed : dynamicCellRadius;
|
|
148490
148496
|
const cellOpacity = cellOpacityMode === "manual" ? cellOpacityFixed : dynamicCellOpacity;
|
|
148491
|
-
const
|
|
148497
|
+
const {
|
|
148498
|
+
normData: uint8ExpressionData,
|
|
148499
|
+
extents: expressionExtents,
|
|
148500
|
+
missing: expressionMissing
|
|
148501
|
+
} = useUint8FeatureSelection(expressionData);
|
|
148492
148502
|
const getExpressionValue = useExpressionValueGetter({
|
|
148493
148503
|
instanceObsIndex: obsEmbeddingIndex,
|
|
148494
148504
|
matrixObsIndex,
|
|
@@ -148700,6 +148710,7 @@ function EmbeddingScatterplotSubscriber(props) {
|
|
|
148700
148710
|
featureValueColormapRange: geneExpressionColormapRange,
|
|
148701
148711
|
obsSetSelection: cellSetSelection,
|
|
148702
148712
|
extent: expressionExtents == null ? void 0 : expressionExtents[0],
|
|
148713
|
+
missing: expressionMissing == null ? void 0 : expressionMissing[0],
|
|
148703
148714
|
pointsVisible: embeddingPointsVisible,
|
|
148704
148715
|
contoursVisible: embeddingContoursVisible,
|
|
148705
148716
|
contoursFilled: embeddingContoursFilled,
|
package/dist/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { i as inflate_1 } from "./pako.esm-68f84e2a.js";
|
|
2
|
-
import { g as getDefaultExportFromCjs, B as BaseDecoder } from "./index-
|
|
2
|
+
import { g as getDefaultExportFromCjs, B as BaseDecoder } from "./index-b29153a1.js";
|
|
3
3
|
import "react";
|
|
4
4
|
import "@vitessce/vit-s";
|
|
5
5
|
import "react-dom";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"EmbeddingScatterplotSubscriber.d.ts","sourceRoot":"","sources":["../src/EmbeddingScatterplotSubscriber.js"],"names":[],"mappings":"AAyCA;;;;;;;;;;;;GAYG;AACH,sDAVG;IAAsB,IAAI,EAAlB,MAAM;IACQ,KAAK,EAAnB,MAAM;IACQ,kBAAkB,EAAhC,MAAM;IAEU,mBAAmB;IAErB,KAAK,EAAnB,MAAM;IACQ,kBAAkB,EAAhC,MAAM;CAEhB,
|
|
1
|
+
{"version":3,"file":"EmbeddingScatterplotSubscriber.d.ts","sourceRoot":"","sources":["../src/EmbeddingScatterplotSubscriber.js"],"names":[],"mappings":"AAyCA;;;;;;;;;;;;GAYG;AACH,sDAVG;IAAsB,IAAI,EAAlB,MAAM;IACQ,KAAK,EAAnB,MAAM;IACQ,kBAAkB,EAAhC,MAAM;IAEU,mBAAmB;IAErB,KAAK,EAAnB,MAAM;IACQ,kBAAkB,EAAhC,MAAM;CAEhB,eA0gBA"}
|
|
@@ -156,7 +156,7 @@ export function EmbeddingScatterplotSubscriber(props) {
|
|
|
156
156
|
const getCellIsSelected = useCallback((object, { index }) => ((cellSelectionSet || new Set([])).has(obsEmbeddingIndex[index]) ? 1.0 : 0.0), [cellSelectionSet, obsEmbeddingIndex]);
|
|
157
157
|
const cellRadius = (cellRadiusMode === 'manual' ? cellRadiusFixed : dynamicCellRadius);
|
|
158
158
|
const cellOpacity = (cellOpacityMode === 'manual' ? cellOpacityFixed : dynamicCellOpacity);
|
|
159
|
-
const
|
|
159
|
+
const { normData: uint8ExpressionData, extents: expressionExtents, missing: expressionMissing, } = useUint8FeatureSelection(expressionData);
|
|
160
160
|
// Set up a getter function for gene expression values, to be used
|
|
161
161
|
// by the DeckGL layer to obtain values for instanced attributes.
|
|
162
162
|
const getExpressionValue = useExpressionValueGetter({
|
|
@@ -258,7 +258,7 @@ export function EmbeddingScatterplotSubscriber(props) {
|
|
|
258
258
|
}, updateViewInfo: setComponentViewInfo, getExpressionValue: getExpressionValue, getCellIsSelected: getCellIsSelected, obsSetSelection: cellSetSelection, sampleSetSelection: sampleSetSelection,
|
|
259
259
|
// InternMap data structures where keys are
|
|
260
260
|
// obsSet -> sampleSet -> arrayKey -> [].
|
|
261
|
-
stratifiedData: stratifiedData, obsSetColor: cellSetColor, sampleSetColor: sampleSetColor, contourThresholds: contourThresholds, contourColorEncoding: contourColorEncoding, contourColor: contourColor, contoursFilled: embeddingContoursFilled, embeddingPointsVisible: embeddingPointsVisible, embeddingContoursVisible: embeddingContoursVisible }), tooltipsVisible && (_jsx(ScatterplotTooltipSubscriber, { parentUuid: uuid, obsHighlight: cellHighlight, width: width, height: height, getObsInfo: getObsInfo })), _jsx(Legend, { visible: true, theme: theme, featureType: featureType, featureValueType: featureValueType, obsColorEncoding: cellColorEncoding, featureSelection: geneSelection, featureLabelsMap: featureLabelsMap, featureValueColormap: geneExpressionColormap, featureValueColormapRange: geneExpressionColormapRange, obsSetSelection: cellSetSelection, extent: expressionExtents?.[0],
|
|
261
|
+
stratifiedData: stratifiedData, obsSetColor: cellSetColor, sampleSetColor: sampleSetColor, contourThresholds: contourThresholds, contourColorEncoding: contourColorEncoding, contourColor: contourColor, contoursFilled: embeddingContoursFilled, embeddingPointsVisible: embeddingPointsVisible, embeddingContoursVisible: embeddingContoursVisible }), tooltipsVisible && (_jsx(ScatterplotTooltipSubscriber, { parentUuid: uuid, obsHighlight: cellHighlight, width: width, height: height, getObsInfo: getObsInfo })), _jsx(Legend, { visible: true, theme: theme, featureType: featureType, featureValueType: featureValueType, obsColorEncoding: cellColorEncoding, featureSelection: geneSelection, featureLabelsMap: featureLabelsMap, featureValueColormap: geneExpressionColormap, featureValueColormapRange: geneExpressionColormapRange, obsSetSelection: cellSetSelection, extent: expressionExtents?.[0], missing: expressionMissing?.[0],
|
|
262
262
|
// Contour percentile legend
|
|
263
263
|
pointsVisible: embeddingPointsVisible, contoursVisible: embeddingContoursVisible, contoursFilled: embeddingContoursFilled, contourPercentiles: contourPercentiles || DEFAULT_CONTOUR_PERCENTILES, contourThresholds: contourThresholds })] }));
|
|
264
264
|
}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vitessce/scatterplot-embedding",
|
|
3
|
-
"version": "3.
|
|
4
|
-
"author": "
|
|
3
|
+
"version": "3.5.1",
|
|
4
|
+
"author": "HIDIVE Lab at HMS",
|
|
5
5
|
"homepage": "http://vitessce.io",
|
|
6
6
|
"repository": {
|
|
7
7
|
"type": "git",
|
|
@@ -20,12 +20,12 @@
|
|
|
20
20
|
"d3-array": "^2.4.0",
|
|
21
21
|
"lodash-es": "^4.17.21",
|
|
22
22
|
"react-aria": "^3.28.0",
|
|
23
|
-
"@vitessce/constants-internal": "3.
|
|
24
|
-
"@vitessce/legend": "3.
|
|
25
|
-
"@vitessce/scatterplot": "3.
|
|
26
|
-
"@vitessce/sets-utils": "3.
|
|
27
|
-
"@vitessce/utils": "3.
|
|
28
|
-
"@vitessce/vit-s": "3.
|
|
23
|
+
"@vitessce/constants-internal": "3.5.1",
|
|
24
|
+
"@vitessce/legend": "3.5.1",
|
|
25
|
+
"@vitessce/scatterplot": "3.5.1",
|
|
26
|
+
"@vitessce/sets-utils": "3.5.1",
|
|
27
|
+
"@vitessce/utils": "3.5.1",
|
|
28
|
+
"@vitessce/vit-s": "3.5.1"
|
|
29
29
|
},
|
|
30
30
|
"devDependencies": {
|
|
31
31
|
"react": "^18.0.0",
|
|
@@ -333,7 +333,11 @@ export function EmbeddingScatterplotSubscriber(props) {
|
|
|
333
333
|
const cellRadius = (cellRadiusMode === 'manual' ? cellRadiusFixed : dynamicCellRadius);
|
|
334
334
|
const cellOpacity = (cellOpacityMode === 'manual' ? cellOpacityFixed : dynamicCellOpacity);
|
|
335
335
|
|
|
336
|
-
const
|
|
336
|
+
const {
|
|
337
|
+
normData: uint8ExpressionData,
|
|
338
|
+
extents: expressionExtents,
|
|
339
|
+
missing: expressionMissing,
|
|
340
|
+
} = useUint8FeatureSelection(expressionData);
|
|
337
341
|
|
|
338
342
|
// Set up a getter function for gene expression values, to be used
|
|
339
343
|
// by the DeckGL layer to obtain values for instanced attributes.
|
|
@@ -559,6 +563,7 @@ export function EmbeddingScatterplotSubscriber(props) {
|
|
|
559
563
|
featureValueColormapRange={geneExpressionColormapRange}
|
|
560
564
|
obsSetSelection={cellSetSelection}
|
|
561
565
|
extent={expressionExtents?.[0]}
|
|
566
|
+
missing={expressionMissing?.[0]}
|
|
562
567
|
// Contour percentile legend
|
|
563
568
|
pointsVisible={embeddingPointsVisible}
|
|
564
569
|
contoursVisible={embeddingContoursVisible}
|