## Re: AI-GEOSTATS: ai-geostats: Simulating spatial autocorrelation?

Expand Messages
• Mark, Try BMElib, at http://www.unc.edu/depts/case/BMELIB/ Example 1: Generate a field on a 10Km by 10Km grid with 1Km increment using an exponential
Message 1 of 2 , Nov 1 12:35 PM
Mark,
Try BMElib, at http://www.unc.edu/depts/case/BMELIB/

Example 1: Generate a field on a 10Km by 10Km grid with 1Km increment
using an exponential covariance with variance=4, range=5Km and
mean=12,

[X Y]=meshgrid(0:10,0:10);
covmodel='exponentialC';
covparam=[4 5];
z=12+simuchol([X(:) Y(:)],covmodel,covparam);
pcolor(X,Y,reshape(z,11,11));

See fig1.jpeg

Example 2: Generate a field at 40 random points in the same domain
using the same covariance and mean:

p=10*rand(40,2);
Z=12+simuchol(p,covmodel,covparam);
colorplot(p,Z);

See fig2.jpeg

Note, attached is the MATLAB file used to generate the jpeg figures
included in this email.

Cheers,
Marc Serre
Research Assistant Professor
Center for the Advanced Study of the Environment (CASE)
Department of Environmental Sciences and Engineering (DESE)
The University of North Carolina at Chapel Hill
CB 7400, 104 Rosenau Hall
Chapel Hill, NC 27599-7431, USA
e-mail: marc_serre@...
phone: 919-966-7014
fax: 919-966-7911
homepage: http://www.unc.edu/~mserre/ESEhome.html
BMElib: http://www.unc.edu/depts/case/BMELIB/

-----Original Message-----
From: Mark C Andersen <manderse@...>
To: ai-geostats@... <ai-geostats@...>
Date: Thursday, November 01, 2001 11:49 AM
Subject: AI-GEOSTATS: ai-geostats: Simulating spatial autocorrelation?

Hello all,

I'm looking for code (preferably MATLAB) or pseudocode
to simulate a 2D spatially-autocorrelated grid with
user-settable autocorrelation. I'd also like to find
an algorithm for generating a fractal on a grid.

I'm just generating simulated habitats for simulation
studies of animal population dynamics and foraging. I
don't (at this time) need to simulate conditionally on
data.

Dr. Mark C. Andersen, Associate Professor
Department of Fishery and Wildlife Sciences
Campus Box 4901
New Mexico State University
Las Cruces, NM 88003-0003
phone: 505-646-8034
fax: 505-646-1281

--
* To post a message to the list, send it to ai-geostats@...
* As a general service to the users, please remember to post a summary
of any useful responses to your questions.
* To unsubscribe, send an email to majordomo@... with no subject
and "unsubscribe ai-geostats" followed by "end" on the next line in
the message body. DO NOT SEND Subscribe/Unsubscribe requests to the
list
* Support to the list is provided at http://www.ai-geostats.org

[Non-text portions of this message have been removed]
Your message has been successfully submitted and would be delivered to recipients shortly.