1"use strict";(globalThis.webpackChunkturf_www||=[]).push([[1017],{89319(e,n,t){t.r(n),t.d(n,{assets:()=>h,contentTitle:()=>u,default:()=>g,frontMatter:()=>d,metadata:()=>r,toc:()=>p});const r=JSON.parse('{"id":"api/rbush","title":"rbush","description":"{() => }","source":"@site/versioned_docs/version-7.1.0/api/rbush.mdx","sourceDirName":"api","slug":"/api/rbush","permalink":"/docs/7.1.0/api/rbush","draft":false,"unlisted":false,"editUrl":"https://github.com/Turfjs/turf-www/tree/master/versioned_docs/version-7.1.0/api/rbush.mdx","tags":[],"version":"7.1.0","frontMatter":{"title":"rbush"},"sidebar":"apiSidebar","previous":{"title":"quadratAnalysis","permalink":"/docs/7.1.0/api/quadratAnalysis"},"next":{"title":"standardDeviationalEllipse","permalink":"/docs/7.1.0/api/standardDeviationalEllipse"}}');var i=t(86070),s=t(67028),o=t(64776),a={};t.r(a),t.d(a,{along:()=>o.Qwm,angle:()=>o.g7h,applyFilter:()=>o.$hf,area:()=>o.Wcw,areaFactors:()=>o.i26,azimuthToBearing:()=>o.Oe8,bbox:()=>o.Qk1,bboxClip:()=>o.ywB,bboxPolygon:()=>o.kJI,bearing:()=>
1o.dcc,bearingToAzimuth:()=>o.u8E,bezierSpline:()=>o.vKl,booleanClockwise:()=>o.D2R,booleanConcave:()=>o.U7O,booleanContains:()=>o.yxm,booleanCrosses:()=>o.hkq,booleanDisjoint:()=>o.t5S,booleanEqual:()=>o.x0k,booleanIntersects:()=>o.lgr,booleanOverlap:()=>o.cYD,booleanParallel:()=>o.Y5$,booleanPointInPolygon:()=>o.mFO,booleanPointOnLine:()=>o.O84,booleanTouches:()=>o.UsQ,booleanValid:()=>o.hxF,booleanWithin:()=>o.Cei,buffer:()=>o.ra8,center:()=>o.gXo,centerMean:()=>o.rb,centerMedian:()=>o.eZr,centerOfMass:()=>o.NAY,centroid:()=>o.vh2,circle:()=>o.n1W,cleanCoords:()=>o.ayX,clone:()=>o.o8B,cloneProperties:()=>o.Rdw,clusterEach:()=>o.UZ0,clusterReduce:()=>o.HYf,clusters:()=>o.qf7,clustersDbscan:()=>o.Zqw,clustersKmeans:()=>o.pPd,collect:()=>o.Fod,collectionOf:()=>o.iww,combine:()=>o.kg7,concave:()=>o.Ms8,containsNumber:()=>o.lOq,convertArea:()=>o.vnt,convertLength:()=>o.I3T,convex:()=>o.y5H,coordAll:()=>o.D3w,coordEach:()=>o.Fh1,coordReduce:()=>o.k7X,createBins:()=>o.f8u,degreesToRadians:()=>o.tRv,destination:()=>o.j_,difference:()=>o.iv2,directionalMean:()=>o.eFb,dissolve:()=>o.a1F,distance:()=>o.IoC,distanceWeight:()=>o.mJ,earthRadius:()=>o.zXD,ellipse:()=>o.pw2,envelope:()=>o.REH,explode:()=>o.Gdr,factors:()=>o.PgN,feature:()=>o.N4z,featureCollection:()=>o.Lrk,featureEach:()=>o.usj,featureOf:()=>o.mo4,featureReduce:()=>o.n4j,filterProperties:()=>o.qV7,findPoint:()=>o.Yd2,findSegment:()=>o.ptW,flatten:()=>o.Bqz,flattenEach:()=>o.iwz,flattenReduce:()=>o.VJK,flip:()=>o.UUz,geojsonRbush:()=>o.sZS,geojsonType:()=>o.e8v,geomEach:()=>o.kX6,geomReduce:()=>o.jEc,geometry:()=>o.lCx,geometryCollection:()=>o.zbs,getCluster:()=>o.dB3,getCoord:()=>o.uGX,getCoords:()=>o.$Rn,getGeom:()=>o.bgk,getType:()=>o.Pwh,greatCircle:()=>o.Glg,helpers:()=>o._$r,hexGrid:()=>o.O9B,interpolate:()=>o.GWP,intersect:()=>o.y$5,invariant:()=>o.V1S,isNumber:()=>o.EtT,isObject:()=>o.Gvm,isobands:()=>o.Mii,isolines:()=>o.LNI,kinks:()=>o.nUT,length:()=>o.Bw9,lengthToDegrees:()=>o.vlv,lengthToRadians:()=>o.GfV,lineArc:()=>o.FsR,lineChunk:()=>o.W26,lineEach:()=>o.Iet,lineIntersect:()=>o.kVe,lineOffset:()=>o.uO7,lineOverlap:()=>o._Jg,lineReduce:()=>o.t0h,lineSegment:()=>o.wdR,lineSlice:()=>o.ne9,lineSliceAlong:()=>o.qMT,lineSplit:()=>o.JQ7,lineString:()=>o.wiw,lineStrings:()=>o.Nls,lineToPolygon:()=>o.gP4,mask:()=>o.dKf,meta:()=>o.mIj,midpoint:()=>o.PVF,moranIndex:()=>o.KFB,multiLineString:()=>o.NUZ,multiPoint:()=>o.kBJ,multiPolygon:()=>o.g52,nearestNeighborAnalysis:()=>o.rBB,nearestPoint:()=>o.xCI,nearestPointOnLine:()=>o.W1F,nearestPointToLine:()=>o.K9N,planepoint:()=>o.xYr,point:()=>o.zx7,pointGrid:()=>o.hq2,pointOnFeature:()=>o.QwJ,pointToLineDistance:()=>o.d4V,pointToPolygonDistance:()=>o.fJX,points:()=>o.WRA,pointsWithinPolygon:()=>o.nj9,polygon:()=>o.n1,polygonSmooth:()=>o.bmV,polygonTangents:()=>o.v4M,polygonToLine:()=>o.CNZ,polygonize:()=>o.Tz9,polygons:()=>o.qFD,projection:()=>o.Qju,propEach:()=>o.nPV,propReduce:()=>o.qBo,propertiesContainsFilter:()=>o.NLl,quadratAnalysis:()=>o.txz,radiansToDegrees:()=>o.nv6,radiansToLength:()=>o.cJD,random:()=>o.yTv,randomLineString:()=>o.lWQ,randomPoint:()=>o._eC,randomPolygon:()=>o.myJ,randomPosition:()=>o.Dxs,rectangleGrid:()=>o.K1I,rewind:()=>o.KrA,rhumbBearing:()=>o.Fc$,rhumbDestination:()=>o.rmV,rhumbDistance:()=>o.EUY,round:()=>o.LIG,sample:()=>o.XM1,sector:()=>o.rkH,segmentEach:()=>o.RPu,segmentReduce:()=>o.OQs,shortestPath:()=>o._6q,simplify:()=>o.CRN,square:()=>o.EwI,squareGrid:()=>o.cS4,standardDeviationalEllipse:()=>o.C0c,tag:()=>o.TcI,tesselate:()=>o.nYW,tin:()=>o.ucs,toMercator:()=>o.FU4,toWgs84:()=>o.zY8,transformRotate:()=>o.qS_,transformScale:()=>o.nIv,transformTranslate:()=>o.tLh,triangleGrid:()=>o.Vwd,truncate:()=>o.xvE,union:()=>o.KCZ,unkinkPolygon:()=>o.BoU,validateBBox:()=>o.O6s,validateId:()=>o.GZo,voronoi:()=>o.B8d});t(36796);var l=t(35876),c=t(25333);const d={title:"rbush"},u=void 0,h={},p=[{value:"Description",id:"description",level:3},{value:"Parameters",id:"parameters",level:3},{value:"Returns",id:"returns",level:3},{value:"Examples",id:"examples",level:3},{value:"Installation",id:"installation",level:3}];function m(e){const n={a:"a",code:"code",em:"em",h3:"h3",p:"p",pre:"pre",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",...(0,s.R)(),...e.components};return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(c.A,{children:()=>(0,i.jsx)(l.A,{turf:a})}),"\n",(0,i.jsx)(n.h3,{id:"description",children:"Description"}),"\n",(0,i.jsxs)(n.p,{children:["GeoJSON implementation of ",(0,i.jsx)(n.a,{href:"https://github.com/mourner/rbush#rbush",children:"RBush"})," spatial index."]}),"\n",(0,i.jsx)(n.h3,{id:"parameters",children:"Parameters"}),"\n",(0,i.jsxs)(n.table,{children:[(0,i.jsx)(n.thead,{children:(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.th,{children:"Name"}),(0,i.jsx)(n.th,{children:"Type"}),(0,i.jsx)(n.th,{children:"Description"})]})}),(0,i.jsx)(n.tbody,{children:(0,i.jsxs)(n.tr,{children:[(0,i.jsxs)(n.td,{children:["maxEntries",(0,i.jsx)("i",{children:"?"})]}),(0,i.jsx)(n.td,{children:(0,i.jsx)(n.strong,{children:"number"})}),(0,i.jsxs)(n.td,{children:["defines the maximum number of entries in a tree node. 9 (used by default) is a reasonable choice for most applications. Higher value means faster insertion and slower search, and vice versa. ",(0,i.jsx)(n.em,{children:"(default 9)"})]})]})})]}),"\n",(0,i.jsx)(n.h3,{id:"returns",children:"Returns"}),"\n",(0,i.jsx)("ul",{children:(0,i.jsxs)(n.p,{children:[(0,i.jsx)(n.strong,{children:"RBush"})," GeoJSON RBush"]})}),"\n",(0,i.jsx)(n.h3,{id:"examples",children:"Examples"}),"\n",(0,i.jsx)(n.pre,{children:(0,i.jsx)(n.code,{className:"language-javascript",children:'var geojsonRbush = require("geojson-rbush").default;\nvar tree = geojsonRbush();\n'})}),"\n",(0,i.jsx)(n.h3,{id:"installation",children:"Installation"}),"\n",(0,i.jsx)(n.pre,{children:(0,i.jsx)(n.code,{className:"language-javascript",children:'$ npm install @turf/geojson-rbush\n\nimport { rbush } from "@turf/geojson-rbush";\nconst result = rbush(...);\n'})}),"\n",(0,i.jsx)(n.pre,{children:(0,i.jsx)(n.code,{className:"language-javascript",children:'$ npm install @turf/turf\n\nimport * as turf from "@turf/turf";\nconst result = turf.rbush(...);\n'})})]})}function g(e={}){const{wrapper:n}={...(0,s.R)(),...e.components};return n?(0,i.jsx)(n,{...e,children:(0,i.jsx)(m,{...e})}):m(e)}}}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.