EasyKrig30的说明文档kriging插值

上传人:沈*** 文档编号:122863698 上传时间:2022-07-21 格式:DOC 页数:13 大小:197KB
收藏 版权申诉 举报 下载
EasyKrig30的说明文档kriging插值_第1页
第1页 / 共13页
EasyKrig30的说明文档kriging插值_第2页
第2页 / 共13页
EasyKrig30的说明文档kriging插值_第3页
第3页 / 共13页
资源描述:

《EasyKrig30的说明文档kriging插值》由会员分享,可在线阅读,更多相关《EasyKrig30的说明文档kriging插值(13页珍藏版)》请在装配图网上搜索。

1、The GLOBEC Kriging Software Package EasyKrig3.0July 15, 2004Copyright (c) 1998, 2001, 2004 property of Dezhang Chu and Woods Hole Oceanographic Institution. All Rights Reserved.The kriging software described in this document was developed by Dezhang Chu with funding from the National Science Foundat

2、ion through the U.S. GLOBEC Georges Bank Projects Program Service and Data Management Office. It was originally inspired by a MATLAB toolbox developed by Yves Gratton and Caroline Lafleur (INRS-Ocanologie, Rimouski, Qc, Canada), and Jeff Runge (Institut Maurice-Lamontagne, now with University of New

3、 Hampshire). This software may be reproduced for noncommercial purposes only.This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY. Contact Dr. Chu at with enhancements or suggestions for changes.Table of Contents:1. INTRODUCTION1.1 General Information1.1.1 About k

4、riging1.1.2 Brief descriptions of easy_krig3.01.2 Getting started1.2.1 Operating systems1.2.2 Down-load the program1.2.3 Quick start2. DATA PROCESSING STAGES2.1 Data Preparation2.2 Semi-variogram2.3 Kriging2.4 Visualization2.5 Saving Kriging Results3. EXAMPLES 3.1 Example 1: An Aerial Image of Zoopl

5、ankton Abundance Data 3.2 Example 2: A Vertical Section of Salinity Data An Anisotropic Data set 3.3 Example 3: Batch Process of Pressure (dbar) at Different Potential Density Layers 3.4 Example 4: 3-Dimensional Temperature Data4. REFERENCES1. INTRODUCTION1.1 General Information1.1.1 About krigingTh

6、is section provides a brief theoretical background for kriging. If the user(s) is not interested in the theoretical background, he/she can skip this section and go to section 1.1.2 directly.Kriging is a technique that provides the Best Linear Unbiased Estimator of the unknown fields (Journel and Hui

7、jbregts, 1978; Kitanidis, 1997). It is a local estimator that can provide the interpolation and extrapolation of the originally sparsely sampled data that are assumed to be reasonably characterized by the Intrinsic Statistical Model (ISM). An ISM does not require the quantity of interest to be stati

8、onary, i.e. its mean and standard deviation are independent of position, but rather that its covariance function depends on the separation of two data points only, i.e.E (z(x) m)(z(x) m) = C(h),(1)where m is the mean of z(x) and C(h) is the covariance function with lag h, with h being the distance b

9、etween two samples x and x:h = | x x | = (2)Another way to characterize an ISM is to use a semi-variogram,= 0.5* E (z(x) z(x) )2.(3)The relation between the covariance function and the semi-variogram is = C(0) C(h).(4)The kriging method is to find a local estimate of the quantity at a specified loca

10、tion, . This estimate is a weighted average of the N adjacent observations:(5)The weighting coefficients can be determined based on the minimum estimation variance criterion:(6)subject to the normalization condition . (7)Note that we dont know the exact value at , but we are trying to find a predict

11、ed value that provides the minimum estimation variance. The resultant kriging equation can be expressed as ,(8)where m is the Lagrangian coefficient. In addition, we have replaced the covariance function with the normalized covariance function normalized by C(0). Equivalently, by using Eq. (4), the

12、kriging equation can also be expressed in terms of the semi-variogram as ,(9)where we have used normalized semi-variogram, i.e., semi-variogram normalized by C(0) as we did in deriving Eq. (8).Having obtained the weighting coefficients ( ) and the Lagrangian coefficient ( ) by solving either Eq. (8)

13、 OR Eq. (9), the kriging variance, Eq. (6), can be expressed as:.(10)The above equations are the basis of the Easykrig software package.1.1.2 Brief description of EasyKrig3.0The EasyKrig program package uses a Graphical User Interface (GUI). It requires MATLAB 5.3 or higher with or without optimizat

14、ion toolbox (see section 2.2) and consists of five components, or processing stages: (1) data preparation, (2) variogram computation, (3) kriging, (4) visualization and (5) saving results. It allows the user to process anisotropic data, select an appropriate model from a list of variogram models, an

15、d a choice of kriging methods, as well as associated kriging parameters, which are also common features of the other existing software packages. One of the major advantages of this program package is that the program minimizes the users requirements to guess the initial parameters and automatically

16、generates the required default parameters. In addition, because it uses a GUI, the modifications from the initial parameter settings can be easily performed. Another feature of this program package is that it has a built-in on-line help library that allows the user to obtain the descriptions of the

17、use of parameters and operation options easily.The current EasyKrig3.0 is the upgraded version of the previous version (EasyKrig2.1). In addition to having corrected some programming errors in the previous version (mostly GUI related errors), there are many new features included in the current versi

18、on: Matlab Version 6.x and 7.0 (tested under Windows) compatible Capable of handling 3-D data Enhanced batch capability More flexible in loading input data and saving output data Capable of handling the customized grid examples with detailed step by step instructions are provided to allow user(s) to

19、 master the functionality of the software package more quickly and easily.Although this software package lacks some abilities such as Co-kriging, it does provide a convenient tool for geostatistical applications and should also help scientists from other fields.For people who do not want to use GUI

20、but only interested in function-based m-files can go to a different website that provides a function-based m- package () developed by Caroline Lafleur and Yves Gratton, INRS-Ocanologie, Universit du Qubec Rimouski.1.2 Getting Started1.2.1 Operating systemsThe software was originally developed under

21、MATLAB 6.5 on a PC (windows 2000) and intended to be computer and/or operating system independent. The program has been tested on various machines (PC, Macintosh, and Sun Workstation) and operating systems (windows 2000/Xp, Linux) and performs fine. 1.2.2 Down-load the program The user needs to down

22、load the compressed GLOBEC web site first, the URL isu/pub/software/kriging/easy_krig/V3.0.1/and the compressed Windows 95/98/NT/2000/XP, Macintosh and Linux:easy_krig30.zip Unix:easy_krig30.tar.gz After having downloaded the file, the user needs to uncompress the file. A directory of easy_krig3.0 w

23、ill be created and you are ready to run the program.1.2.3 Quick startStart MATLAB and go to the designated easy_krig3.0 home directory. Just type “startkrig” in the MATLAB command window, a window will pop up. This window is the base window, called the Navigator window. The Menubar in this window co

24、ntains many options you can choose. Now you are ready to move on.Note: You can add the kriging home directory to the Matlab search path and run the program from other directories. However, you have to make sure that there are no functions of your own having the same names as those used for easy_krig

25、3.0. Since the program will allow you to load and save files using a , it is recommended that you run the program under the easy_krig3.0 home directory. The program provides a full on-line help function that provides the descriptions the use of almost all of the selectable functions, options, and pa

26、rameters. It is quite self-explanatory and easy to use. 2. DATA PROCESSING STAGESThere are several data processing stages (tasks) that are selectable from the Menubar on the top of the Navigator window, as well as other task windows. By selecting or clicking on any of the tasks, a window correspondi

27、ng to the selected task will pop up. On each task window including the Navigator window, the descriptions and explanations of every option and selection in each task window can be found by click on the “Help” option on the Menubar. On any of the task windows, clicking on the “Navigator” button, or s

28、electing “Navigator” from the Menubar will bring back the Navigator window. 2.1 Data PreparationSelecting “Load Data” from “Task” on the Menubar of any window leads to the Data Preparation window. Click on the “Load” button or select “Load” from the Menubar to load the raw data file. The format of t

29、he data be a 3-column ASCII 2D data and 4-column ASCII 3D data. Comments at the beginning of the data not affect the data as long as each comment line begins with a percentage symbol “%”. User(s) can provide their own m- load the data by using “External Program” option in the Data Preparation window

30、. This function allows the user to generate the input data directly from the raw data instead of generating an ASCII is required by the Easykrig3.0. The required format for the input and output parameters by using an external program can be found by clicking on the “Help” from the Menubar and select

31、ing “External Program”. One can set the other parameters such as reduction factor (or just accept default settings) before loading the file. After the loaded, if the user wants to change the other (default) settings, such as data filter, he/she can do so and then click on “Apply” pushbutton after th

32、e parameters have been set. The difference between “Load” and “Apply” is that the latter operation is faster since it will not re-load the data file. For example, to change the axis labels after having loaded the data, one does not need to re-load the data.One can also save the “Data Format” informa

33、tion into a file, which will save all the parameter and option settings in this window. This feature allows the user(s) to load the data the same settings in the task window Kriging without opening or using this window. It is very useful when a batch process operation is needed (see explanation in 2

34、.3 and the example 3 for more details).The usage of the other options in this window can be found by selecting appropriate items from “Help” option on the Menubar.2.2 Semi-variogramSelecting “Variogram” from “Task” on the Menubar leads to a popup Variogram/Correlogram window. Click on the “Compute”

35、button to generate a data-based semi-variogram (or correlogram). Then, we need to seek a model-based semi-variogram or correlogram to fit the data-based variogram just computed. It can be proved that, based on Eq. (4), the relation between the normalized semi-variogram n(h) normalized by the varianc

36、e C(0) and the correlogram Cn(h) is:Cn(h) = 1 - n(h),where h is the lag distance (Eq. 2). An appropriate variogram/correlogram model can be selected depending on the shape of the variogram/correlogram computed from the data. The explanations of the parameters associated with the model can be found u

37、sing the on-line help. Click on the “Apply” button and the program will compute the model-based variogram/correlogram using the current settings. The parameter settings can be changed either by changing the slider positions or by entering the numbers directly into the associated text-edit fields. If

38、 using the slider, the theoretical curve will change automatically, while if entering the number(s) into the text-edit field(s), the user needs to click on the “Apply” button to re-compute the curve.If the optimization toolbox (recommended) is installed, the user can use the Least-Squares Fit functi

39、on to fit the data by clicking on the “LSQ fit” button. If the optimization toolbox isnt installed, the program will automatically disable the Least-Squares fit function.Note that since the LSQ fit has a certain range for each parameter, different initial settings or parameters will produce differen

40、t results.In some cases when the data are anisotropic, an anisotropic variogram or correlogram model can be activated. By selecting “Anisotropy” radio option, the corresponding settings are enabled. If you dont know or are not sure of the orientation and aspect ratio of the anisotropic feature of th

41、e data, you can use the default settings first and then adjust to obtain satisfactory results. One can save the current variogram parameters to a can also retrieve the variogram parameters previously saved to a file. The usage of the other options in this window can be found by selecting appropriate

42、 items from “Help” option on the Menubar.2.3 KrigingSelecting “Kriging” from “Task” on the Menubar leads to a popup Kriging window. The parameters of the variogram or correlogram needed in the kriging operation are automatically passed from the Variogram window to the Kriging window. Click on the “R

43、efresh” button to obtain the most recent semi-variogram and coordinates parameters if the user has loaded a new data set. The “Relative Variance” parameter will set the kriging values to “NaN” (Not a number) when the kriged values are larger than this parameter and will become blank in the kriging m

44、ap. The default value of this parameter is 2.5.Click on the “Krig” button to start kriging. In general, accepting the default parameters will produce a reasonable kriging map to start with. Changing the variogram and kriging parameters will offer fine-tuning on these parameters and can further impro

45、ve the quality of the kriging results. One of the important features of the EasyKrig is its ability of performing “Batch Process”, which allows the user to process a group of data sets that have the same data structures, i.e., having the same data format and using the same variogram and kriging para

46、meters. The user will provide a which a list of the data be included. The outputs of each data set from kriging will be automatically saved to appropriate Matlab binary format. Another added feature in EasyKrig3.0 is that it allows users to provide their own grid specify the coordinates of regular o

47、r irregular grids on which the kriged values are generated. The usage of the other options in this window can be found by selecting appropriate items from “Help” option on the Menubar.2.4 Visualization Choosing “Visualization” from “Task” on the Menubar leads to the Visualization window. Three types

48、 of figures can be viewed in this window: kriging map, kriging-variance map and cross-validation. The first two maps are commonly used in the kriging literature while the last one is a unique approach of this program. Click on the “Show Plot” button to display the current kriging results.The shading

49、 option is for the display purpose only and their explanations can be found by typing “help shading” in the MATLAB command window.Sliders next to the colorbar case can be used to change the display range of the colormap scale. Sliders next to the X, Y, and Y axes in 3D case are used to change the po

50、sitions of the slices in X, Y, and Z directions, respectively.If the data have been transformed in the Data Preparation window, the kriging results are the results from transformed data. An important feature of the EasyKrig is it can provide “cross-validation”, which can be performed by selecting th

51、e “Validation” radio option. One can compute and display the results from different cross-validation schemes in a separate Cross-Validation window. Among these schemes, the Q1 and Q2 are good indicators that provide a plausible assessment of the performance of the kriging in addition to the kriging-

52、variance map. More detailed descriptions of these cross-validation can be found from the built-in “Help” function. In general, the Q1 criterion (distribution of the deviation for the mean) is easy to satisfy while the Q2 criterion (distribution of deviations for the standard deviation) is much more

53、difficult to satisfy. As a rule of thumb, reducing the area under the theoretical curve of the variogram (smaller nugget, lower sill, smaller length scale, etc.) will increase the Q2 value, while increasing this area will reduce the Q2 value.The usage of the other options in this window can be found

54、 by selecting appropriate items from “Help” option on the Menubar.2.5 Saving Kriging ResultsIn the Visualization window, by selecting “File” from the Menubar and then choosing “Save ”, the user can save the outputs to a .mat a user-defined and at the user-selected location. The program saves the par

55、ameters and data structures (para and data) in the file. For information on the structures, the user needs to select “File” from the Menubar in the Navigator window and then “Variable Structure” to obtain explanations for some important variables (note that many variables are not relevant to users).

56、3. EXAMPLESThere are several sample data files included in the package. All files are in ASCII format required by the program. In the following examples, the designated directory is assumed to be “easy_krig3.0”.3.1 Example 1: An Aerial Image of Zooplankton Abundance Data (1) Start MATLAB, in command

57、 window, change directory to the home directory of EasyKrig3.0. Type “startkrig” to launch the program.(2) Adjust the window size and position and select “Save Window Position” option from “Task” on the Menubar and then “Save Position” from the sub-menu. Note that after saving the window size and po

58、sition, any of other task windows created afterwards will have the same size and at the same position. You can resize and re-position the window in any other task windows as well.(3) Select “Load Data” from “Task” on the Menubar to open the Data Preparation window.(a) Select “Data Col. 2” from the l

59、istbox of “Column” for X-Axis and “Data Col. 1” for Y-Axis (defaults).(b) Select “LONGITUDE” from listbox of “Variable” for X-Axis and “LATITUDE” for Y-Axis (defaults).(c) Leave other parameters unchanged.(d) Click on the “Load” button to open a dialog box, go to “data” directory, and then select th

60、e data file “zooplankton.dat” to load the selected memory.(e) Select “Sample Sequence” in the “Display Type” frame to display the sample sequence. By selecting “2D/3D Color-coded View” to bring back the color-coded display. (4)Select “Variogram” from “Task” on the Menubar to open the Variogram/Corre

61、logram window. (a) Click on the “Compute” button to compute the semi-variogram. This plots the data-based semi-variogram as discrete open circles. (b) Select “general exponential-Bessel” (default) from the variogram model listbox on the upper right. Click on the “LSQ Fit” button. If you dont have op

62、timization toolbox, click on the “Apply” button, a theoretical model-based semi-variogram will be superimposed on the original data-based semi-variogram. The resultant semi-variogram parameters from the least-squares fit (if you have optimization toolbox) or from the default settings (if you dont ha

63、ve optimization toolbox) are shown in the text-edit fields within the “Model Parameters” frame.(c) Click on the sliders associated with the variogram parameters, the theoretical curves will change accordingly to reflect the parameter changes. The parameters can also be changed by entering the values

64、 directly into the text-edit fields and then clicking on the “Apply” pushbutton. (d) Type 0 in the “nugget” text-edit field, 1.0 in the “sill” text-edit field, 0.1 in the “length” text-edit field, 1.5 in the “power” field, and 0 in the hole scl (hole scale) text-edit field. Then, click on the “Apply” button. A revised theoretical curve of the model-based semi-variogram will be generated and plotted (red curve).(e) By selecting

展开阅读全文
温馨提示:
1: 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
2: 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
3.本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
5. 装配图网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。
关于我们 - 网站声明 - 网站地图 - 资源地图 - 友情链接 - 网站客服 - 联系我们

copyright@ 2023-2025  zhuangpeitu.com 装配图网版权所有   联系电话:18123376007

备案号:ICP2024067431-1 川公网安备51140202000466号


本站为文档C2C交易模式,即用户上传的文档直接被用户下载,本站只是中间服务平台,本站所有文档下载所得的收益归上传人(含作者)所有。装配图网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对上载内容本身不做任何修改或编辑。若文档所含内容侵犯了您的版权或隐私,请立即通知装配图网,我们立即给予删除!