This function takes a snap object as input and calculates the jaccard index matrix
in which each entry Jij equals the intersection over the union between cell i and cell j.
A non-empty character vector giving the directory name that saves the temp files
mat
A character class that indicates what matrix slot is used to calculate jaccard index c("bmat", "pmat", "gmat")
max.var
A numeric variable indicates the how many dimentions for jaccard index to be calcualted
seed.use
A numeric variable indicates the random seed to use [10].
Value
Returns a Snap obj with the jaccard index matrix stored in obj@jmat
Details
Calculating jaccard index becomes exponentially time-consuming and also memory
intense with the increase of cell number.
The most memory and time consuming step of our procedure is the calculation of jaccard index matrix.
This step increases exponentially with the increase of cell number. Here, we calculate a partial jaccard
index matrix against a random subset of reference cells in lieu of the full spectrum of features.
Here we tested if we can perform the calculation of partial jaccard index matrix using a random
subset of max.var reference cells.