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  1.812367
#> 
#> $endpoints[[1]][[2]]
#> [1]  1.000000 -1.533618
#> 
#> 
#> $endpoints[[2]]
#> $endpoints[[2]][[1]]
#> [1] -1.0000000  0.1803432
#> 
#> $endpoints[[2]][[2]]
#> [1]  1.0000000 -0.7391864
#> 
#> 
#> $endpoints[[3]]
#> $endpoints[[3]][[1]]
#> [1] -1.000000 -3.404758
#> 
#> $endpoints[[3]][[2]]
#> [1] 1.000000 3.404758
#> 
#> 
#> 
#> $angles
#> [1]  30.86808  65.30869 163.63214
#> 
#> $midpoints
#> $midpoints[[1]]
#> [1] 0.0000000 0.1393745
#> 
#> $midpoints[[2]]
#> [1]  0.0000000 -0.2794216
#> 
#> $midpoints[[3]]
#> [1] 0 0
#> 
#> 
#> $n_lines
#> [1] 3
#>