-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathREADME.Rmd
53 lines (37 loc) · 2.01 KB
/
README.Rmd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
---
output: github_document
editor_options:
chunk_output_type: console
---
<!-- README.md is generated from README.Rmd. Please edit that file -->
```{r, include = FALSE}
knitr::opts_chunk$set(
collapse = TRUE,
comment = "#>",
fig.path = "man/figures/README-",
out.width = "100%"
)
```
# insidesexp
<!-- badges: start -->
[![R-CMD-check](https://github.com/diminutive/insidesexp/workflows/R-CMD-check/badge.svg)](https://github.com/diminutive/insidesexp/actions)
<!-- badges: end -->
The goal of insidesexp is to do fast point in polygon classification, with SEXP and possibly without some of the sp scaffolding
We are comparing a few ways of implementing this, essentially O'Rourke Ch 7 and assuming bbox cull upstream, and ring classification down (for hole status).
```{r example}
coords = structure(c(0.191915028329653, 0.242440023683676,
0.435140005964137, 0.750039977007818, 0.794689972902072,
0.569089993646897, 0.308240017633102, 0.191915028329653,
0.303924266802157, 0.661208259237305, 0.7774331724391,
0.725777655460525, 0.340513591328648, 0.179090100770599,
0.224288678126852, 0.303924266802157), .Dim = c(8L, 2L
))
pts <- structure(c(0.193090028221607, 0.134340033623905, 0.194265028113561,
0.358765012987125, 0.527964997428506, 0.829939969660693, 0.896914963502072,
0.146805402658989, 0.461043130945324, 0.74514847432749, 0.626771247918254,
0.306076580009597, 0.187699353600361, 0.506241708301578), .Dim = c(7L,
2L), .Dimnames = list(NULL, c("x", "y")))
insidesexp::inside_sexp(pts, coords)
```
## Code of Conduct
Please note that the insidesexp project is released with a [Contributor Code of Conduct](https://contributor-covenant.org/version/2/0/CODE_OF_CONDUCT.html). By contributing to this project, you agree to abide by its terms.