{
  "_id": "6a196f00acfb0bcc41dec2a9",
  "Package": "Battlefield",
  "Type": "Package",
  "Title": "Swiss-army toolkit for selecting niche fronts and invasive\nmargins in spatial transcriptomics data",
  "Version": "1.1.0",
  "Authors@R": "c(\nperson(\"Jean-Philippe\",\"Villemin\",email=\"jpvillemin@gmail.com\",role=c(\"aut\", \"cre\"),\ncomment = c(ORCID = \"0000-0002-1838-5880\")),\nperson(\"European Research Council\",\nrole = \"fnd\",\ncomment = \"ERC-2022\"))",
  "Description": "Battlefield is a Swiss-army toolkit originally developed\nto define and extract spatial spots from specific tissue\nregions—such as front regions, niche borders, invasive margins,\nand cluster interfaces—using spatial transcriptomics data or\nclustered tissue maps. It has since been extended to support\ntrajectory selection and layer inspection, and now provides a\ncollection of low-level utilities for spatial transcriptomics\nanalysis. These utilities are primarily intended to be reused\nwithin higher-level analytical packages. It is designed to work\nwith sequencing-based platforms such as Visium at several\nresolutions and Visium HD(binned).",
  "URL": "https://github.com/ZheFrench/BattleField,\nhttps://zhefrench.github.io/Battlefield/",
  "BugReports": "https://github.com/ZheFrench/BattleField/issues",
  "License": "CeCILL | file LICENSE",
  "Encoding": "UTF-8",
  "LazyData": "FALSE",
  "biocViews": "Sequencing, Software, Transcriptomics, Spatial",
  "Config/testthat/edition": "3",
  "RoxygenNote": "7.3.3",
  "VignetteBuilder": "knitr",
  "Config/pak/sysreqs": "zlib1g-dev",
  "Repository": "https://bioc.r-universe.dev",
  "Date/Publication": "2026-04-28 13:06:28 UTC",
  "RemoteUrl": "https://github.com/bioc/Battlefield",
  "RemoteRef": "HEAD",
  "RemoteSha": "69a79b679b63d692eca55dcc994d81be2459b113",
  "NeedsCompilation": "no",
  "Packaged": {
    "Date": "2026-05-29 08:45:02 UTC",
    "User": "root"
  },
  "Author": "Jean-Philippe Villemin [aut, cre] (ORCID:\n<https://orcid.org/0000-0002-1838-5880>),\nEuropean Research Council [fnd] (ERC-2022)",
  "Maintainer": "Jean-Philippe Villemin <jpvillemin@gmail.com>",
  "MD5sum": "0a6f2b98d371c0724d44c1396237f728",
  "_user": "bioc",
  "_type": "src",
  "_file": "Battlefield_1.1.0.tar.gz",
  "_fileid": "58c44abba164a0f05e0897937a64ee84a71d031a5ca8174944603d7bba49fef5",
  "_filesize": 5085659,
  "_sha256": "58c44abba164a0f05e0897937a64ee84a71d031a5ca8174944603d7bba49fef5",
  "_created": "2026-05-29T08:45:02.000Z",
  "_published": "2026-05-29T10:48:32.724Z",
  "_jobs": [
    {
      "job": 78468066283,
      "time": 193,
      "config": "bioc-checks",
      "r": "4.6.0",
      "check": "NOTE",
      "artifact": "7286786023"
    },
    {
      "job": 78468066297,
      "time": 338,
      "config": "linux-devel-x86_64",
      "r": "4.7.0",
      "check": "OK",
      "artifact": "7286830224"
    },
    {
      "job": 78468066295,
      "time": 376,
      "config": "linux-release-x86_64",
      "r": "4.6.0",
      "check": "OK",
      "artifact": "7286842112"
    },
    {
      "job": 78468066298,
      "time": 186,
      "config": "macos-oldrel-arm64",
      "r": "4.5.3",
      "check": "OK",
      "artifact": "7288882325"
    },
    {
      "job": 78468066409,
      "time": 273,
      "config": "macos-release-arm64",
      "r": "4.6.0",
      "check": "OK",
      "artifact": "7288907631"
    },
    {
      "job": 78467240423,
      "time": 333,
      "config": "source",
      "r": "4.6.0",
      "check": "OK",
      "artifact": "7286727324"
    },
    {
      "job": 78468066300,
      "time": 189,
      "config": "wasm-release",
      "r": "4.6.0",
      "check": "OK",
      "artifact": "7286785320"
    },
    {
      "job": 78468066312,
      "time": 376,
      "config": "windows-devel",
      "r": "4.7.0",
      "check": "OK",
      "artifact": "7286842397"
    },
    {
      "job": 78468066321,
      "time": 345,
      "config": "windows-oldrel",
      "r": "4.5.3",
      "check": "OK",
      "artifact": "7286832254"
    },
    {
      "job": 78468066311,
      "time": 384,
      "config": "windows-release",
      "r": "4.6.0",
      "check": "OK",
      "artifact": "7286844382"
    }
  ],
  "_bioccheck": {
    "error": 0,
    "warning": 0,
    "note": 3
  },
  "_buildurl": "https://github.com/r-universe/bioc/actions/runs/26627338298",
  "_status": "success",
  "_host": "GitHub-Actions",
  "_upstream": "https://github.com/bioc/Battlefield",
  "_commit": {
    "id": "69a79b679b63d692eca55dcc994d81be2459b113",
    "author": "A Wokaty <andres.wokaty@sph.cuny.edu>",
    "committer": "A Wokaty <andres.wokaty@sph.cuny.edu>",
    "message": "bump x.y.z version to odd y following creation of RELEASE_3_23 branch\n",
    "time": 1777381588
  },
  "_maintainer": {
    "name": "Jean-Philippe Villemin",
    "email": "jpvillemin@gmail.com",
    "login": "zhefrench",
    "twitter": "@ZheFrench",
    "description": "Bioinformatician - Institute of Cancer Research of Montpellier  : Cancer Genomics / Alternative Splicing / Epigenetic",
    "uuid": 14000664,
    "orcid": "0000-0002-1838-5880"
  },
  "_distro": "noble",
  "_registered": true,
  "_dependencies": [
    {
      "package": "R",
      "version": ">= 4.5",
      "role": "Depends"
    },
    {
      "package": "stats",
      "role": "Imports"
    },
    {
      "package": "RANN",
      "role": "Imports"
    },
    {
      "package": "dplyr",
      "role": "Imports"
    },
    {
      "package": "SummarizedExperiment",
      "role": "Imports"
    },
    {
      "package": "methods",
      "role": "Imports"
    },
    {
      "package": "BiocStyle",
      "role": "Suggests"
    },
    {
      "package": "knitr",
      "role": "Suggests"
    },
    {
      "package": "markdown",
      "role": "Suggests"
    },
    {
      "package": "rmarkdown",
      "role": "Suggests"
    },
    {
      "package": "SpatialExperiment",
      "role": "Suggests"
    },
    {
      "package": "SpatialExperimentIO",
      "role": "Suggests"
    },
    {
      "package": "VisiumIO",
      "role": "Suggests"
    },
    {
      "package": "ggplot2",
      "role": "Suggests"
    },
    {
      "package": "pheatmap",
      "role": "Suggests"
    },
    {
      "package": "pals",
      "role": "Suggests"
    },
    {
      "package": "OSTA.data",
      "role": "Suggests"
    },
    {
      "package": "tidyr",
      "role": "Suggests"
    },
    {
      "package": "STexampleData",
      "role": "Suggests"
    },
    {
      "package": "testthat",
      "version": ">= 3.0.0",
      "role": "Suggests"
    },
    {
      "package": "codetools",
      "role": "Suggests"
    },
    {
      "package": "grid",
      "role": "Suggests"
    },
    {
      "package": "tools",
      "role": "Suggests"
    }
  ],
  "_owner": "bioc",
  "_selfowned": true,
  "_usedby": 0,
  "_updates": [
    {
      "week": "2025-51",
      "n": 14
    },
    {
      "week": "2026-01",
      "n": 1
    },
    {
      "week": "2026-02",
      "n": 16
    },
    {
      "week": "2026-03",
      "n": 4
    },
    {
      "week": "2026-05",
      "n": 5
    },
    {
      "week": "2026-09",
      "n": 1
    },
    {
      "week": "2026-16",
      "n": 1
    },
    {
      "week": "2026-18",
      "n": 2
    }
  ],
  "_tags": [],
  "_bioc": [
    {
      "branch": "devel",
      "version": "1.1.0",
      "bioc": "3.24"
    },
    {
      "branch": "release",
      "version": "1.0.0",
      "bioc": "3.23"
    }
  ],
  "_topics": [
    "sequencing",
    "software",
    "transcriptomics",
    "spatial"
  ],
  "_stars": 0,
  "_contributors": [
    {
      "user": "zhefrench",
      "count": 239,
      "uuid": 14000664
    },
    {
      "user": "jcolinge",
      "count": 71,
      "uuid": 65902924
    }
  ],
  "_userbio": {
    "uuid": 2286807,
    "type": "organization",
    "name": "Bioconductor",
    "description": "Software for the analysis and comprehension of high-throughput genomic data"
  },
  "_downloads": {
    "count": 88,
    "source": "https://www.bioconductor.org/packages/stats/bioc/Battlefield"
  },
  "_devurl": "https://github.com/zhefrench/battlefield",
  "_pkgdown": "https://zhefrench.github.io/Battlefield/",
  "_searchresults": 12,
  "_rbuild": "4.6.0",
  "_assets": [
    "extra/Battlefield.html",
    "extra/citation.cff",
    "extra/citation.html",
    "extra/citation.json",
    "extra/citation.txt",
    "extra/contents.json",
    "extra/NEWS.html",
    "extra/NEWS.txt",
    "extra/readme.html",
    "extra/readme.md",
    "manual.pdf"
  ],
  "_homeurl": "https://github.com/zhefrench/battlefield",
  "_realowner": "bioc",
  "_cranurl": false,
  "_exports": [
    "add_borders_to_spe",
    "add_layers_to_spe",
    "add_trajectories_to_spe",
    "adjacent_endpoint",
    "bresenham_line",
    "build_all_borders",
    "build_all_cores",
    "build_one_line",
    "build_one_trajectory",
    "build_similar_trajectories",
    "closest_spot",
    "compute_centroids",
    "count_all_inlaids",
    "count_all_neighborhoods",
    "count_inlaid",
    "count_neighborhood",
    "create_all_layers",
    "create_cluster_layers",
    "detect_grid_type",
    "directed_cluster_interface_pairs",
    "estimate_spot_spacing",
    "filter_out_by_endpoint_clusters",
    "get_inlaid_spots",
    "get_neighborhood_params",
    "get_neighborhood_spots",
    "point_segment_distance_vec",
    "remove_used_points",
    "select_border_spots",
    "select_core_spots",
    "shift_point",
    "unit_normal_left"
  ],
  "_datasets": [
    {
      "name": "visium_simulated_spe",
      "title": "Simulated Visium SpatialExperiment dataset",
      "object": "visium_simulated_spe",
      "file": "visium_simulated_spe.rda",
      "class": [
        "SpatialExperiment"
      ],
      "fields": [],
      "table": false,
      "tojson": false
    },
    {
      "name": "visiumHD_16um_simulated_spe",
      "title": "Simulated VisiumHD 16 µm binned SpatialExperiment dataset",
      "object": "visiumHD_16um_simulated_spe",
      "file": "visiumHD_16um_simulated_spe.rda",
      "class": [
        "SpatialExperiment"
      ],
      "fields": [],
      "table": false,
      "tojson": false
    },
    {
      "name": "visiumHD_8um_simulated_spe",
      "title": "Simulated VisiumHD 8 µm binned SpatialExperiment dataset",
      "object": "visiumHD_8um_simulated_spe",
      "file": "visiumHD_8um_simulated_spe.rda",
      "class": [
        "SpatialExperiment"
      ],
      "fields": [],
      "table": false,
      "tojson": false
    }
  ],
  "_help": [
    {
      "page": "add_borders_to_spe",
      "title": "Add border or core spot selections to SpatialExperiment colData",
      "topics": [
        "add_borders_to_spe"
      ]
    },
    {
      "page": "add_layers_to_spe",
      "title": "Add layer classifications to SpatialExperiment colData",
      "topics": [
        "add_layers_to_spe"
      ]
    },
    {
      "page": "add_trajectories_to_spe",
      "title": "Add trajectory information to SpatialExperiment colData",
      "topics": [
        "add_trajectories_to_spe"
      ]
    },
    {
      "page": "adjacent_endpoint",
      "title": "Pick a point adjacent to a selected endpoint, on a given side of a segment",
      "topics": [
        "adjacent_endpoint"
      ]
    },
    {
      "page": "bresenham_line",
      "title": "Rasterize a line between two points using Bresenham's algorithm",
      "topics": [
        "bresenham_line"
      ]
    },
    {
      "page": "build_all_borders",
      "title": "Build border spots for all oriented cluster pairs",
      "topics": [
        "build_all_borders"
      ]
    },
    {
      "page": "build_all_cores",
      "title": "Build core spots for all oriented cluster pairs",
      "topics": [
        "build_all_cores"
      ]
    },
    {
      "page": "build_one_line",
      "title": "Build a single line of spots along a segment",
      "topics": [
        "build_one_line"
      ]
    },
    {
      "page": "build_one_trajectory",
      "title": "Select spots near a segment and order them along the segment",
      "topics": [
        "build_one_trajectory"
      ]
    },
    {
      "page": "build_similar_trajectories",
      "title": "Build parallel spot lines around a central segment",
      "topics": [
        "build_similar_trajectories"
      ]
    },
    {
      "page": "closest_spot",
      "title": "Find the closest spot to a target point",
      "topics": [
        "closest_spot"
      ]
    },
    {
      "page": "compute_centroids",
      "title": "Compute cluster centroids (mean x/y per cluster)",
      "topics": [
        "compute_centroids"
      ]
    },
    {
      "page": "count_all_inlaids",
      "title": "Count inlaid composition for all clusters",
      "topics": [
        "count_all_inlaids"
      ]
    },
    {
      "page": "count_all_neighborhoods",
      "title": "Count neighborhood composition for all clusters",
      "topics": [
        "count_all_neighborhoods"
      ]
    },
    {
      "page": "count_inlaid",
      "title": "Count inlaid composition within a source cluster",
      "topics": [
        "count_inlaid"
      ]
    },
    {
      "page": "count_neighborhood",
      "title": "Count annotated spot types in the neighborhood of a cluster or point",
      "topics": [
        "count_neighborhood"
      ]
    },
    {
      "page": "create_all_layers",
      "title": "Create and visualize layers for multiple clusters",
      "topics": [
        "create_all_layers"
      ]
    },
    {
      "page": "create_cluster_layers",
      "title": "Create layer classification for spots in a cluster",
      "topics": [
        "create_cluster_layers"
      ]
    },
    {
      "page": "detect_grid_type",
      "title": "Detect the grid type (square vs hexagonal) from spatial coordinates",
      "topics": [
        "detect_grid_type"
      ]
    },
    {
      "page": "directed_cluster_interface_pairs",
      "title": "Build all oriented cluster pairs (A -> B) and their directed_pair labels",
      "topics": [
        "directed_cluster_interface_pairs"
      ]
    },
    {
      "page": "estimate_spot_spacing",
      "title": "Estimate spot spacing from nearest-neighbor distances",
      "topics": [
        "estimate_spot_spacing"
      ]
    },
    {
      "page": "filter_out_by_endpoint_clusters",
      "title": "Filter lines by endpoint cluster membership",
      "topics": [
        "filter_out_by_endpoint_clusters"
      ]
    },
    {
      "page": "get_inlaid_spots",
      "title": "Get inlaid spots within a source cluster",
      "topics": [
        "get_inlaid_spots"
      ]
    },
    {
      "page": "get_neighborhood_params",
      "title": "Suggest neighborhood parameters based on detected grid type",
      "topics": [
        "get_neighborhood_params"
      ]
    },
    {
      "page": "get_neighborhood_spots",
      "title": "Get neighborhood spots around a target cluster or point",
      "topics": [
        "get_neighborhood_spots"
      ]
    },
    {
      "page": "point_segment_distance_vec",
      "title": "Point-to-segment distance (vectorized)",
      "topics": [
        "point_segment_distance_vec"
      ]
    },
    {
      "page": "remove_used_points",
      "title": "Remove rows whose rounded (x, y) coordinates have already been used",
      "topics": [
        "remove_used_points"
      ]
    },
    {
      "page": "select_border_spots",
      "title": "Select border spots from cluster A that touch cluster B (and flag junctions)",
      "topics": [
        "select_border_spots"
      ]
    },
    {
      "page": "select_core_spots",
      "title": "Select core (non-interface) spots for a directed pair",
      "topics": [
        "select_core_spots"
      ]
    },
    {
      "page": "shift_point",
      "title": "Shift a point along a given direction vector",
      "topics": [
        "shift_point"
      ]
    },
    {
      "page": "unit_normal_left",
      "title": "Compute the left unit normal of the directed segment A->B",
      "topics": [
        "unit_normal_left"
      ]
    },
    {
      "page": "visium_simulated_spe",
      "title": "Simulated Visium SpatialExperiment dataset",
      "topics": [
        "visium_simulated_spe"
      ]
    },
    {
      "page": "visiumHD_16um_simulated_spe",
      "title": "Simulated VisiumHD 16 µm binned SpatialExperiment dataset",
      "topics": [
        "visiumHD_16um_simulated_spe"
      ]
    },
    {
      "page": "visiumHD_8um_simulated_spe",
      "title": "Simulated VisiumHD 8 µm binned SpatialExperiment dataset",
      "topics": [
        "visiumHD_8um_simulated_spe"
      ]
    }
  ],
  "_pkglogo": "https://github.com/bioc/Battlefield/raw/HEAD/man/figures/logo.png",
  "_readme": "https://github.com/bioc/Battlefield/raw/HEAD/README.md",
  "_rundeps": [
    "abind",
    "Biobase",
    "BiocGenerics",
    "cli",
    "DelayedArray",
    "dplyr",
    "generics",
    "GenomicRanges",
    "glue",
    "IRanges",
    "lattice",
    "lifecycle",
    "magrittr",
    "Matrix",
    "MatrixGenerics",
    "matrixStats",
    "pillar",
    "pkgconfig",
    "R6",
    "RANN",
    "rlang",
    "S4Arrays",
    "S4Vectors",
    "Seqinfo",
    "SparseArray",
    "SummarizedExperiment",
    "tibble",
    "tidyselect",
    "utf8",
    "vctrs",
    "withr",
    "XVector"
  ],
  "_vignettes": [
    {
      "source": "Battlefield-Main.Rmd",
      "filename": "Battlefield-Main.html",
      "title": "Battlefield",
      "author": "Jean-Philippe Villemin",
      "engine": "knitr::rmarkdown",
      "headings": [
        "Introduction",
        "What is it for?",
        "Starting point",
        "Interfaces between clusters",
        "Intra-cluster layers",
        "Inter/Intra-cluster trajectories",
        "Spatial neighborhood",
        "Ending point",
        "Session Information"
      ],
      "created": "2026-01-02 16:24:48",
      "modified": "2026-02-27 11:29:35",
      "commits": 10
    }
  ],
  "_score": 4.681241237375588,
  "_indexed": true,
  "_nocasepkg": "battlefield",
  "_universes": [
    "bioc",
    "zhefrench"
  ],
  "_binaries": [
    {
      "r": "4.7.0",
      "os": "linux",
      "version": "1.1.0",
      "date": "2026-05-29T08:49:08.000Z",
      "distro": "noble",
      "commit": "69a79b679b63d692eca55dcc994d81be2459b113",
      "fileid": "776e9784ad8791776b45e373d798fff83dcb5b7a53c51341b9cbc1358546e909",
      "status": "success",
      "check": "OK",
      "buildurl": "https://github.com/r-universe/bioc/actions/runs/26627338298"
    },
    {
      "r": "4.6.0",
      "os": "linux",
      "version": "1.1.0",
      "date": "2026-05-29T08:49:49.000Z",
      "distro": "noble",
      "commit": "69a79b679b63d692eca55dcc994d81be2459b113",
      "fileid": "378c77fac1462a8b41040305584d392dc3ea7f9b07ee5b8b839d976404bb382d",
      "status": "success",
      "check": "OK",
      "buildurl": "https://github.com/r-universe/bioc/actions/runs/26627338298"
    },
    {
      "r": "4.5.3",
      "os": "mac",
      "version": "1.1.0",
      "date": "2026-05-29T10:45:25.000Z",
      "commit": "69a79b679b63d692eca55dcc994d81be2459b113",
      "fileid": "a724c413230f0fd1bf1c2477e935141cefa534a368396292bb5c735265d42d02",
      "status": "success",
      "check": "OK",
      "buildurl": "https://github.com/r-universe/bioc/actions/runs/26627338298"
    },
    {
      "r": "4.6.0",
      "os": "mac",
      "version": "1.1.0",
      "date": "2026-05-29T10:46:08.000Z",
      "commit": "69a79b679b63d692eca55dcc994d81be2459b113",
      "fileid": "b7c0cd29a0b365e1fd99053a498baa31b81d258ec6a119df0f610ce9bdd8523d",
      "status": "success",
      "check": "OK",
      "buildurl": "https://github.com/r-universe/bioc/actions/runs/26627338298"
    },
    {
      "r": "4.6.0",
      "os": "wasm",
      "version": "1.1.0",
      "date": "2026-05-29T08:48:46.000Z",
      "commit": "69a79b679b63d692eca55dcc994d81be2459b113",
      "fileid": "bae3b308c30cc6465a2b0e84c4940c385c6a98b4cedb8650e097589c731941d8",
      "status": "success",
      "buildurl": "https://github.com/r-universe/bioc/actions/runs/26627338298"
    },
    {
      "r": "4.7.0",
      "os": "win",
      "version": "1.1.0",
      "date": "2026-05-29T08:49:52.000Z",
      "commit": "69a79b679b63d692eca55dcc994d81be2459b113",
      "fileid": "bce22e749d68e09c2146a7e28e73c740d2b9a4060b874fa550d4d9374ed2eeab",
      "status": "success",
      "check": "OK",
      "buildurl": "https://github.com/r-universe/bioc/actions/runs/26627338298"
    },
    {
      "r": "4.5.3",
      "os": "win",
      "version": "1.1.0",
      "date": "2026-05-29T08:49:07.000Z",
      "commit": "69a79b679b63d692eca55dcc994d81be2459b113",
      "fileid": "3fbfce8cd2ff9a2264a7da2af5d6471038d1b3baa0400bd1133b5fad08437f5a",
      "status": "success",
      "check": "OK",
      "buildurl": "https://github.com/r-universe/bioc/actions/runs/26627338298"
    },
    {
      "r": "4.6.0",
      "os": "win",
      "version": "1.1.0",
      "date": "2026-05-29T08:49:42.000Z",
      "commit": "69a79b679b63d692eca55dcc994d81be2459b113",
      "fileid": "e8806b0c12a4327476dfe231bc6f8f50c265115e8e7fc18ae7b1335a3934f658",
      "status": "success",
      "check": "OK",
      "buildurl": "https://github.com/r-universe/bioc/actions/runs/26627338298"
    }
  ]
}