⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 fwholesale2.m

📁 空间统计工具箱
💻 M
字号:
function [eouts, erecs, alphamaxes, bmaxes]=fwholesale2(xall, yall, d,  start, nsub, obsindices, xcoord, ycoord)
%[eouts,erecs,alphamaxes,bmaxes]=fwholesale2(xall, yall, d,  start, nsub, obsindices, xcoord, ycoord)
%
%This function computes a set of spatial autoregressive local
%estimates (SALE) where the ith SALE are centered at xcoord(obsindices(i)),
%ycoord(obsindices(i)). Each SALE uses at minimum start observations and at
%maximum nsub observations. 
%
%INPUT:
%
%xall is a n by k matrix containing the n observations on k independent variables for the
%global sample
%
%yall contains y and its spatial lag dy where dy=d*y . This is a n by 2
%matrix.
%
%d is an n by n symmetric spatial weight matrix
%
%start is the minimum number of observations used for any SALE (start>k)
%
%nsub is the maximum number of observations used for any SALE
%
%obsindices are the observations numbers of the desired centers of the SALE
%samples. This is a jiter by 1 vector. 
%
%xcoord, ycoord are both n by 1 vectors of locational coordinates
%
%
%OUTPUT:
%eouts are nsub residuals of the holdout observation at
%xcoord(obsindices(i)), ycoord(obsindices(i)) for i=1....jiter. It is a
%nsub by jiter matrix.
%
%erces are nsub residuals from predicting the i+1 observations based upon observations 2 to i (observation 1 is held out as well).
%These are recursive residuals
%
%alphamaxes are the matrix of nsub by jiter spatial dependence parameters.
%
%bmaxes are a sequence of beta estimates for the sequence of samples
%start:i for i=start:nsub.
%
%NOTES:
%
%If you wish to run SALE for a large number of indices, you may need to
%edit this function to not store every statistic for each subsample
%regression.
%
%If you use these functions, please cite:
%Pace, R. Kelley, and James LeSage, 揝patial Autoregressive Local Estimation,

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -