function rectContains(selection, points) {
            if (selection) {
                var isBrushed = selection[0][0] <= points.yMainG && selection[1][0] >= points.yMainG && // Check X coordinate
                        selection[0][1] <= points.xMainG && selection[1][1] >= points.xMainG  // And Y coordinate
                //Remember points are at (y,x)
                return isBrushed;
            }
        }
// Helper function for determining which nodes are in brush
Helper function for determining which nodes are in brush
Helper function for determining which nodes are in brush
function rectContains(selection, points) {
            if (selection) {
                var isBrushed = selection[0][0] <= points.yMainG && selection[1][0] >= points.yMainG && 
                        selection[0][1] <= points.xMainG && selection[1][1] >= points.xMainG  
                return isBrushed;
            }
        }
function rectContains ( selection , points ) { if ( selection ) { var isBrushed = selection [ 0 ] [ 0 ] <= points . yMainG && selection [ 1 ] [ 0 ] >= points . yMainG && selection [ 0 ] [ 1 ] <= points . xMainG && selection [ 1 ] [ 1 ] >= points . xMainG return isBrushed ; } }
Helper function for determining which nodes are in brush
Helper function for determining which nodes are in brush
// Check X coordinate // And Y coordinate //Remember points are at (y,x)