Extract the count in each iteration

get_search_count(dt, iter = NULL, group = NULL)

Arguments

dt

a data object collected by the projection pursuit guided tour optimisation in the tourr package

iter

the variable to be counted by

group

the variable to label different runs of the optimiser(s)

Value

a tibble object of the number of searches conducted by the optimiser(s) in each iteration

See also

Examples

get_search_count(holes_1d_better)
#> map tries to the x-axis
#> # A tibble: 6 x 2 #> tries n #> <dbl> <int> #> 1 1 1 #> 2 2 6 #> 3 3 1 #> 4 4 7 #> 5 5 3 #> 6 6 24
get_search_count(dplyr::bind_rows(holes_1d_better, holes_1d_geo), group = method)
#> map tries to the x-axis
#> # A tibble: 16 x 3 #> # Groups: tries [10] #> tries method n #> <dbl> <chr> <int> #> 1 1 search_better 1 #> 2 2 search_better 6 #> 3 3 search_better 1 #> 4 4 search_better 7 #> 5 5 search_better 3 #> 6 6 search_better 24 #> 7 1 search_geodesic 1 #> 8 2 search_geodesic 11 #> 9 3 search_geodesic 11 #> 10 4 search_geodesic 11 #> 11 5 search_geodesic 11 #> 12 6 search_geodesic 11 #> 13 7 search_geodesic 11 #> 14 8 search_geodesic 11 #> 15 9 search_geodesic 22 #> 16 10 search_geodesic 264