nnspat0.1.2 package

Nearest Neighbor Methods for Spatial Patterns

funsXsq.nnsym.ss

Pielou's First Type of NN Symmetry Test with Chi-square Approximation ...

funsXsq.seg.coeff

Chi-square Test for Segregation Coefficients

bvnorm.pdf

pdf of the Bivariate Normal Distribution

funs.auxcovtct

Auxiliary Functions for Computing Covariances Between Cell Counts in t...

funsXsq.nnsym.dx

Dixon's NN Symmetry Test with Chi-square Approximation for multiple cl...

funs.base.class.spec

Base Class-specific Chi-square Tests based on NNCTs

funs.overall.seg

Overall Segregation Tests for NNCTs

funs.cell.spec.ss

Pielou's Cell-specific Segregation Test with Normal Approximation (for...

funs.class.spec

Class-specific Chi-square Tests based on NNCTs

aij.theta

Closeness or Proximity Matrix for Tango's Spatial Clustering Tests

funs.covNii

Covariance Matrix of the Self Entries in a Species Correspondence Cont...

funs.covtct

Functions for Covariances of the Entries of the Types I, III and IV TC...

asycovTkTl

Asymptotic Covariance between TkT_k and TlT_l Values

asyvarTk

Asymptotic Variance of Cuzick and Edwards TkT_k Test statistic

cellsTij

Entries for the Types I-IV cell-specific tests

ceTk

Cuzick and Edwards TkT_k Test statistic

ceTkinv

Cuzick and Edwards TkinvT_k^{inv} Test statistic

ceTrun

Cuzick and Edwards TrunT_{run} Test statistic

cov.nnct

Covariance Matrix of the Cell Counts in an NNCT

cov.nnsym

Covariance Matrix of the Differences of the Off-Diagonal Cell Counts i...

cov.seg.coeff

Covariance Matrix of Segregation Coefficients in a Multi-class Case

cov.tct

Covariance Matrix of the Entries of the Type I-IV TCTs

covNrow2col

Conversion of the Covariance Matrix of the Row-wise Vectorized Cell Co...

covTcomb

Covariance matrix for TkT_k values in Tcomb

covTkTl

Finite Sample Covariance between TkT_k and TlT_l Values

dist.std.data

Interpoint Distance Matrix for Standardized Data

dist2full

Converts a lower triangular distance matrix to a full distance matrix

dot-onAttach

.onAttach start message

dot-onLoad

.onLoad getOption package settings

euc.dist

The Euclidean distance between two vectors, matrices, or data frames

EV.Nii

Expected Values of the Self Entries in a Species Correspondence Contin...

EV.nnct

Expected Values of the Cell Counts in NNCT

EV.rct

Expected Values of the Cell Counts in RCT

EV.Tcomb

Expected Value for Cuzick & Edwards TcombT_{comb} Test Statistic

EV.tct

Expected Values of the Types I-IV cell-specific tests

EV.tctI

Expected Values of the Type I cell-specific tests

EV.Tkinv

Expected Value of Cuzick and Edwards TkinvT_k^{inv} Test statistic

exact.nnct

Exact version of Pearson's chi-square test on NNCTs

exact.pval1s

pp-value correction to the one-sided version of exact NNCT test

exact.pval2s

pp-value correction to the two-sided version of exact NNCT test

funs.kNNdist

Functions for the kthk^{th} and k NN distances

funs.kNNdist2cl

Functions for the kthk^{th} and k NN distances

funs.overall.nnct

Dixon's Overall Test of Segregation for NNCT

funs.overall.tct

Types I-IV Overall Tests of Segregation for NNCT

funs.pijPij

The functions for probability of selecting a number of points from res...

funs.scct

Species Correspondence Contingency Table (SCCT)

funs.seg.coeff

Pielou's Segregation Coefficients for NNCTs

funs.varNii

Variances of the Self Entries in a Species Correspondence Contingency ...

funs.vartct

Functions for Variances of Cell Counts in the Types I, III and IV TCTs

funsAijmat

Aij matrices for computation of Moments of Cuzick and Edwards TkT_k Te...

funsC_MI_II

Correction Matrices for the Covariance Matrix of NNCT entries

funsExpTk

Expected Value for Cuzick and Edwards TkT_k Test statistic

funsExpTrun

Expected Value for Cuzick and Edwards TrunT_{run} Test statistic

funsN_I_II

Correction Matrices for the NNCT entries

funsNNclass.spec

NN Class-specific Chi-square Tests based on NNCTs

funsOnevsRest

Functions for one versus rest type labeling

funsPseg.ss

Pielou's Overall Test of Segregation for NNCT (for Sparse Sampling)

funsQandR

Functions for the number of shared NNs, shared NN vector, and the numb...

funsRowColSums

Functions for row and column sums of a matrix

funsVarTk

Variance of Cuzick and Edwards TkT_k Test statistic

funsVarTrun

Variance of Cuzick and Edwards TrunT_{run} Test statistic

funsW345values

WkW_k values for Tango's TT test statistic

funsXsq.nnref

Reflexivity Test with Chi-square Approximation

funsXsq.spec.cor

Overall Species Correspondence Test with Chi-square Approximation

funsZcell.nnct.pval

pp-values for Cell-specific Z Test Statistics for NNCT

funsZcell.nnct

Dixon's Cell-specific Z Tests of Segregation for NNCT

funsZcell.spec

Cell-specific Z Tests of Segregation for NNCTs

funsZcell.tct

Types I-IV Cell-specific Z Tests of Segregation based on NNCTs

funsZdir.nnct

Directional Segregation Test for Two Classes with Normal Approximation

funsZdir.nnct.ss

Directional Segregation Test for Two Classes with Normal Approximation...

funsZmixed.nonref

Mixed-Non-Reflexivity Test with Normal Approximation

funsZnnref

Z Tests for NN Reflexivity

funsZnnself

Self-Reflexivity Tests with Normal Approximation

funsZnnself.sum

Cumulative Species Correspondence Test with Normal Approximation

funsZnnsym.dx

Dixon's Pairwise NN Symmetry Test with Normal Approximation

funsZnnsym.ss

Pielou's Pairwise NN Symmetry Test with Normal Approximation (for Spar...

funsZnnsym2cl.dx

Dixon's NN Symmetry Test with Normal Approximation for Two Classes

funsZnnsym2cl.ss

Pielou's First Type of NN Symmetry Test with Normal Approximation for ...

funsZseg.coeff

Z Tests for Segregation Coefficients

funsZsegind

Z Tests for Segregation Indices

funsZself.ref

Self-Reflexivity Test with Normal Approximation

funsZTkinv

Z-Test for Cuzick and Edwards TkinvT_k^{inv} statistic

ind.nnsym

Index Matrix for Computing the Covariance of Dixon's Overall NN Symmet...

ind.seg.coeff

Index Matrix for Computing the Covariance of Segregation Coefficients

ipd.mat.euc

Euclidean Interpoint Distance Matrix

ipd.mat

Interpoint Distance Matrix

kNN

Finding the indices of the k NNs of a given point

mat2vec

Conversion of a Matrix to a Vector

matrix.sqrt

Square root of a matrix

Ninv

Vector of Shared NNs and Number of Reflexive NNs

NN

Finding the index of the NN of a given point

nnct.boot.dis

Bootstrap Nearest Neighbor Contingency Table (NNCT)

nnct

Nearest Neighbor Contingency Table (NNCT)

nnct.sub

Nearest Neighbor Contingency Table (NNCT) with (only) base points rest...

NNdist

Distances between subjects and their NNs

NNdist2cl

Distances between subjects from class iiand their NNs from class jj

nnspat-package

nnspat: A package for NN Methods and Their Use in Testing Spatial Patt...

NNsub

Finding the index of the NN of a given point among a subset of points

Nt.def

NtN_t Value (found with the definition formula)

Ntkl

NtklN_{tkl} Value

pairwise.lab

Keeping the pair of the specified labels in the data

pick.min.max

Smallest and Largest Distances in a Distance Matrix

pk

Probability of k items selected from the class with size n1n_1

plot.Clusters

Plot a Clusters object

plot.SpatPatterns

Plot a SpatPatterns object

print.cellhtest

Print a summary of a cellhtest object

print.Chisqtest

Print a summary of a Chisqtest object

print.classhtest

Print a summary of a classhtest object

print.Clusters

Print a Clusters object

print.refhtest

Print a summary of a refhtest object

print.SpatPatterns

Print a SpatPatterns object

print.summary.Clusters

Print a summary of a Clusters object

print.summary.SpatPatterns

Print a summary of a SpatPatterns object

prob.nnct

Probability of the current nearest neighbor contingency table

QRval

Number of Shared and Reflexive NNs

Qsym.ct

QQ-symmetry Contingency Table (QCT)

Qsym.test

Pielou's Second Type of NN Symmetry Test with Chi-square Approximation

rassoc

Generation of Points Associated with a Given Set of Points

rassocC

Generation of Points Associated in the Type C Sense with a Given Set o...

rassocG

Generation of Points Associated in the Type G Sense with a Given Set o...

rassocI

Generation of Points Associated in the Type I Sense with a Given Set o...

rassocU

Generation of Points Associated in the Type U Sense with a Given Set o...

rct

Reflexivity Contingency Table (RCT)

rdiag.clust

Generation of Points with Clusters along the First Diagonal

rhor.clust

Generation of Points with Clusters along the Horizontal Axis

rnonRL

Non-Random Labeling of a Given Set of Points

rnonRLI

Type I Non-Random Labeling of a Given Set of Points

rnonRLII

Type II Non-Random Labeling of a Given Set of Points

rnonRLIII

Type III Non-Random Labeling of a Given Set of Points

rnonRLIV

Type IV Non-Random Labeling of a Given Set of Points

rrot.clust

Generation of Points with Rotational Clusters

rseg

Generation of Points under Segregation of Two Classes

rself.ref

Generation of Points from Self Correspondence Pattern

runif.circ

Generation of Uniform Points in a Circle

seg.ind

Dixon's Segregation Indices for NNCTs

sharedNNmc

The Shared NN Vectors for Multiple Classes

SkewTk

Skewness of Cuzick and Edwards TkT_k Test statistic

summary.Clusters

Return a summary of a Clusters object

summary.SpatPatterns

Return a summary of a SpatPatterns object

Tcomb

Cuzick & Edwards Tcomb Test Statistic

tct

TT Contingency Table (TCT)

tocher.cor

Tocher's randomized correction to the exact pp-value

Tval

TT value in NN structure

var.nnct

Variances of Cell Counts in an NNCT

var.nnsym

Variances of Differences of Off-Diagonal Entries in an NNCT

var.seg.coeff

Variances of Segregation Coefficients in a Multi-class Case

var.tct

Variances of Entries in a TCT

varPseg.coeff

Variance of Pielou's Segregation Coefficient for 2 Classes

varTkinv.sim

Simulated Variance of Cuzick and Edwards TkinvT_k^{inv} Test statistic

Wmat

The incidence matrix W for the NN digraph

Xsq.ceTk

Chi-square Approximation to Cuzick and Edwards TkT_k Test statistic

Xsq.nnsym

Overall NN Symmetry Test with Chi-square Approximation

ZceTk

ZZ-test for Cuzick and Edwards TkT_k statistic

Znnsym

NN Symmetry Test with Normal Approximation

Znnsym2cl

NN Symmetry Test with Normal Approximation for Two Classes

ZTcomb

ZZ-test for Cuzick and Edwards TcombT_{comb} statistic

ZTrun

ZZ-test for Cuzick and Edwards TrunT_{run} statistic

Contains the functions for testing the spatial patterns (of segregation, spatial symmetry, association, disease clustering, species correspondence, and reflexivity) based on nearest neighbor relations, especially using contingency tables such as nearest neighbor contingency tables (Ceyhan (2010) <doi:10.1007/s10651-008-0104-x> and Ceyhan (2017) <doi:10.1016/j.jkss.2016.10.002> and references therein), nearest neighbor symmetry contingency tables (Ceyhan (2014) <doi:10.1155/2014/698296>), species correspondence contingency tables and reflexivity contingency tables (Ceyhan (2018) <doi:10.2436/20.8080.02.72> for two (or higher) dimensional data. The package also contains functions for generating patterns of segregation, association, uniformity in a multi-class setting (Ceyhan (2014) <doi:10.1007/s00477-013-0824-9>), and various non-random labeling patterns for disease clustering in two dimensional cases (Ceyhan (2014) <doi:10.1002/sim.6053>), and for visualization of all these patterns for the two dimensional data. The tests are usually (asymptotic) normal z-tests or chi-square tests.

  • Maintainer: Elvan Ceyhan
  • License: GPL-2
  • Last published: 2023-12-19