Skip to contents

Cutting-line endpoints for Coombs-mesh plots

Usage

morie_spatial_voting_cutting_lines(normals, cutpoints, xlim = c(-1, 1))

Arguments

normals

(n_votes x n_dims) normal vectors.

cutpoints

Numeric cutpoint offsets.

xlim

Length-2 numeric vector of x-axis limits.

Value

List with endpoints (list of pairs), angles, midpoints, n_lines.

References

Poole (2005).

Examples

morie_spatial_voting_cutting_lines(matrix(rnorm(6), 3, 2), c(0.1, -0.2, 0))
#> $endpoints
#> $endpoints[[1]]
#> $endpoints[[1]][[1]]
#> [1] -1.000000  4.789938
#> 
#> $endpoints[[1]][[2]]
#> [1]  1.000000 -5.376502
#> 
#> 
#> $endpoints[[2]]
#> $endpoints[[2]][[1]]
#> [1] -1.0000000  0.1710815
#> 
#> $endpoints[[2]][[2]]
#> [1] 1.000000 0.174768
#> 
#> 
#> $endpoints[[3]]
#> $endpoints[[3]][[1]]
#> [1] -1.0000000 -0.3495567
#> 
#> $endpoints[[3]][[2]]
#> [1] 1.0000000 0.3495567
#> 
#> 
#> 
#> $angles
#> [1] -168.87057  -89.89439  109.26742
#> 
#> $midpoints
#> $midpoints[[1]]
#> [1]  0.0000000 -0.2932822
#> 
#> $midpoints[[2]]
#> [1] 0.0000000 0.1729248
#> 
#> $midpoints[[3]]
#> [1] 0 0
#> 
#> 
#> $n_lines
#> [1] 3
#>