adrian0010 / Percolation

1 stars 0 forks source link

[enhance] Function which.precol #30

Closed discoleo closed 1 year ago

discoleo commented 1 year ago

Function which.percol

Enhanced version of the function:

R Code

which.percol = function(m) {
    nc = ncol(m);
    id1 = m[, 1];
    id2 = m[, nc];
    id2 = id2[id2 > 0];
    idP = intersect(id2, id1);
    return(idP);
}