USCounties(Matrix)
USCounties()所属R语言包:Matrix
USCounties Contiguity Matrix
USCounties邻接矩阵
译者:生物统计家园网 机器人LoveR
描述----------Description----------
This matrix represents the contiguities of 3111 US counties using the Queen criterion of at least a single shared boundary point. The representation is as a row standardised spatial weights matrix transformed to a symmetric matrix (see Ord (1975), p. 125).
此矩阵代表contiguities 3111美国使用至少一个共享的边界点的皇后标准的县。代表性的是一排标准化的空间权重矩阵转化为对称矩阵(见条例(1975),第125页)。
用法----------Usage----------
格式----------Format----------
A 3111 ^2 symmetric sparse matrix of class dsCMatrix with 9101 non-zero entries.
一个3111 ^2对称稀疏矩阵类dsCMatrix9101非零项。
Details
详情----------Details----------
The data were read into R using read.gal, and row-standardised and transformed to symmetry using nb2listw and similar.listw. This spatial weights object was converted to class dsCMatrix using as_dsTMatrix_listw and coercion.
使用使用read.gal和nb2listwsimilar.listw,和行标准化,并转化为对称的数据读入R。此对象的空间权重转换类dsCMatrix用as_dsTMatrix_listw和胁迫。
源----------Source----------
The data were retrieved from http://sal.uiuc.edu/weights/zips/usc.zip, files “usc.txt” and “usc\_q.GAL”, with permission for use and distribution from Luc Anselin.
从http://sal.uiuc.edu/weights/zips/usc.zip,的“usc.txt”文件和“USC \ _q.GAL”的许可使用和分配吕克Anselin,检索数据。
参考文献----------References----------
Estimation methods for models of spatial interaction; Journal of the American Statistical Association 70, 120–126.
举例----------Examples----------
data(USCounties)
(n <- ncol(USCounties))
IM <- .symDiagonal(n)
nn <- 50
set.seed(1)
rho <- runif(nn, 0, 1)
system.time(MJ <- sapply(rho, function(x) determinant(IM - x * USCounties, logarithm = TRUE)$modulus))
nWC <- -USCounties
C1 <- Cholesky(nWC, Imult = 2)
system.time(MJ1 <- n * log(rho) +
sapply(rho, function(x) c(determinant(update(C1, nWC, 1/x))$modulus)))
all.equal(MJ, MJ1)
C2 <- Cholesky(nWC, super = TRUE, Imult = 2)
system.time(MJ2 <- n * log(rho) +
sapply(rho, function(x) c(determinant(update(C2, nWC, 1/x))$modulus)))
all.equal(MJ, MJ2)
system.time(MJ3 <- n * log(rho) + Matrix:::ldetL2up(C1, nWC, 1/rho))
all.equal(MJ, MJ3)
system.time(MJ4 <- n * log(rho) + Matrix:::ldetL2up(C2, nWC, 1/rho))
all.equal(MJ, MJ4)
转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。
注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
|