Nothing more than coo_lw(coo)[1]
.
Details
This function can be used to integrate size - if meaningful - to Coo objects. See also coo_centsize and rescale.
See also
Other coo_ descriptors:
coo_angle_edges()
,
coo_angle_tangent()
,
coo_area()
,
coo_boundingbox()
,
coo_chull()
,
coo_circularity()
,
coo_convexity()
,
coo_eccentricity
,
coo_elongation()
,
coo_lw()
,
coo_rectangularity()
,
coo_rectilinearity()
,
coo_scalars()
,
coo_solidity()
,
coo_tac()
,
coo_width()
Examples
coo_length(bot[1])
#> [1] 1087.831
coo_length(bot)
#> brahma caney chimay corona deusventrue
#> 1087.8309 994.1615 643.8746 805.9889 886.0715
#> duvel franziskaner grimbergen guiness hoegardeen
#> 606.0107 865.0272 765.0962 742.1752 1048.1058
#> jupiler kingfisher latrappe lindemanskriek nicechouffe
#> 984.2303 718.3227 737.3475 821.1190 686.2766
#> pecheresse sierranevada tanglefoot tauro westmalle
#> 928.6771 654.2412 680.6856 984.3941 768.0226
#> amrut ballantines bushmills chivas dalmore
#> 864.0899 707.8465 882.0460 793.0187 672.0897
#> famousgrouse glendronach glenmorangie highlandpark jackdaniels
#> 608.2238 822.0508 986.0991 705.9991 793.1392
#> jb johnniewalker magallan makersmark oban
#> 1008.1334 337.7117 759.0041 851.3161 862.0016
#> oldpotrero redbreast tamdhu wildturkey yoichi
#> 596.0958 426.0429 1008.3194 1097.1657 712.1001
mutate(bot, size=coo_length(bot))
#> Out (outlines)
#> - 40 outlines, 162 +/- 21 coords (in $coo)
#> - 3 classifiers (in $fac):
#> # A tibble: 40 × 3
#> type fake size
#> <fct> <fct> <dbl>
#> 1 whisky a 1088.
#> 2 whisky a 994.
#> 3 whisky a 644.
#> 4 whisky a 806.
#> 5 whisky a 886.
#> 6 whisky a 606.
#> # ℹ 34 more rows
#> - also: $ldk