findNN: Find the nearest neighbour (NN) given a cell and a group of...

Description Usage Arguments Value Examples

View source: R/findNN.R

Description

Find the nearest neighbour (NN) given a cell and a group of cells;

Usage

1
2
findNN(cell, cellList, XY_LABELS = c("Cell.X.Position",
  "Cell.Y.Position"))

Arguments

cell

An object cell

cellList

A list of cell types to be calculated for

XY_LABELS

x and y positions of the cell

Value

The Nearest Neibour Cell distance and calculate the distance

Examples

1
2
3
4
5
6
7
Cell.X.Position=sample (1:100,1)
Cell.Y.Position=sample (1:100,1)
Tcell=data.frame(Cell.X.Position,Cell.Y.Position)
Cell.X.Position=sample(1:500,5,replace=TRUE)
Cell.Y.Position=sample(1:500,5,replace=TRUE)
Tumor.cells=data.frame(Cell.X.Position,Cell.Y.Position)
findNN(Tcell,Tumor.cells,XY_LABELS=c('Cell.X.Position', 'Cell.Y.Position'))

ISAT documentation built on May 2, 2019, 9:12 a.m.