R/calculate_distance_to_tumour_margin.R
    calculate_distance_to_margin.RdReturns a SPE object with the minimum distance from cells of interest (CoI) to the identified bordering cells.
calculate_distance_to_margin(spe_object)An spe_object with a `Distance.To.Border` column is returned.
spe_border <- identify_bordering_cells(SPIAT::defined_image,
reference_cell = "Tumour", feature_colname = "Cell.Type", n_to_exclude = 10)
#> [1] "The alpha of Polygon is: 63.24375"
 spe_dist <- calculate_distance_to_margin(spe_border)
#> [1] "Markers had been selected in minimum distance calculation: "
#> [1] "Non-border" "Border"
spe_dist <- calculate_distance_to_margin(spe_border)
#> [1] "Markers had been selected in minimum distance calculation: "
#> [1] "Non-border" "Border"