Draws the scars of one core as arrows from start to end. If an outline is given, also draws the outline, the fitted plane of intersection and its centre, and colours each scar by its Centripetality Index (CPI): blue for scars running towards the centre (180 degrees), grey along the edge (90), red away from the centre (0). Use it to check that scars and outline share a coordinate frame (the starts should lie on the outline) before reading CPI and PRA.
Arguments
- data
A scar table. If it holds several cores,
idselects one.- id
The ID of the core to draw. May be omitted when
dataholds a single core.- outline
Optional outline of the core (see
fit_intersection_plane()) or a plane fitted withfit_intersection_plane().- id_col
Name of the core ID column. Default
"ID".- start_cols, end_cols
Names of the start- and end-point coordinate columns (X, Y, Z). Defaults
Start_X/Y/ZandEnd_X/Y/Z, the columns the scars are recorded in. The aligned columns ofalign_scar_batch()(s_x... ande_x...) give the same results: these indices do not change when a core is rotated or moved.- min_length
Scars shorter than this (in the units of the coordinates) are left out. Default 0 (keep all). Use it to repeat an analysis without small scars, for example
min_length = 10for 10 mm.
Examples
t <- seq(0, 2 * pi, length.out = 13)[-13]
start <- cbind(30 * cos(t), 30 * sin(t), 0)
end <- start * 0.4
end[, 3] <- -5
one <- data.frame(ID = "disc", Start_X = start[, 1], Start_Y = start[, 2],
Start_Z = start[, 3], End_X = end[, 1], End_Y = end[, 2],
End_Z = end[, 3])
u <- seq(0, 2 * pi, length.out = 200)
plot_core(one, outline = cbind(30 * cos(u), 30 * sin(u), 0))
#> Warning: Outline of core disc: collapsing to unique 'x' values
#> Warning: Outline of core disc: collapsing to unique 'x' values
#> Warning: Outline of core disc: collapsing to unique 'x' values
