mirror of
https://github.com/chanzuckerberg/cellxgene.git
synced 2026-10-11 04:00:56 +08:00
add comments
This commit is contained in:
@@ -37,10 +37,15 @@ class BitArray {
|
|||||||
this.bitarray = new Int32Array(this.width * this.length);
|
this.bitarray = new Int32Array(this.width * this.length);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Return the number of records that are selected, ie, have a one bit in
|
||||||
|
// all allocated dimensions.
|
||||||
|
//
|
||||||
get selectionCount() {
|
get selectionCount() {
|
||||||
return this.countAllOnes();
|
return this.countAllOnes();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Count all records that have a 'one' bit in allocated dimensions.
|
||||||
|
//
|
||||||
countAllOnes() {
|
countAllOnes() {
|
||||||
let count = 0;
|
let count = 0;
|
||||||
for (let i = 0; i < this.width; i++) {
|
for (let i = 0; i < this.width; i++) {
|
||||||
|
|||||||
Reference in New Issue
Block a user