proc retrieveVariogramModelParameters { file } {
set name [$file getCurrentValue]
if {"$name" != ""} {
set buffer [GuidoExecServer "GetVariogramModellingParameters" [subst {VGModelName = "$name"} ]]
set status [GuidoGetParamBufferValue $buffer status]
if {$status >= 0} {
global model
$model setCurrentValue [GuidoGetParamBufferValue $buffer ModelType]
global nugget
$nugget setCurrentValue [GuidoGetParamBufferValue $buffer Nugget]
set num_structures [GuidoGetParamBufferValue $buffer NumStructures]
if {$num_structures > 5} {
set num_structures 5
}
for {set idx 0} {$idx < $num_structures} {incr idx} {
global sill$idx
upvar 0 "sill$idx" field
$field setCurrentValue [GuidoGetParamBufferValue $buffer "Sill$idx"]
global range$idx
upvar 0 "range$idx" field
$field setCurrentValue [GuidoGetParamBufferValue $buffer "Range$idx"]
}
}
}
return 1
}
GuidoForm frm00676 {
-default_buttons
-label "Kriging Parameters"
-layout BoxLayout Y_AXIS
-tip "00676_TIP_0"
GuidoPanel frm00676_16 {
-layout BoxLayout X_AXIS
GuidoPanel frm00676_13 {
-layout CentreLineLayout
GuidoFiller frm00676_17 {}
GuidoLabel frm00676_2 {
-font_style bold
-label VARIOGRAM
}
GuidoFileBrowserField vg_model_file_name {
-action valueChanged {[retrieveVariogramModelParameters $vg_model_file_name]}
-display_length 22
-file_access read
-file_mask "*.vgm *.not"
-format none
-label "File name"
-max_length 256
-null true
-translate none
-tip GST_VG_FILENAME_TIP
}
GuidoPanel frm00676_8 {
-label Model
-layout BoxLayout X_AXIS
-tip "Select the variogram model to be used from those available using the browser."
GuidoButtonGroupPanel model {
GuidoRadioButton frm00676_6 {
-caption Spherical
-default true
-selected_value Spherical
}
GuidoRadioButton frm00676_7 {
-caption Exponential
-next_focus nugget
-selected_value Exponential
}
}
}
GuidoField nugget {
-default 0
-display_length 10
-format double
-label Nugget
-low_bound 0
-max_length 20
-next_focus sill0
-null false
-tip "20101_TIP_003"
-translate upper
}
}
GuidoFiller frm00676_18 {
-width 1
}
GuidoPanel frm00676_14 {
-layout BoxLayout Y_AXIS
GuidoLabel frm00676_3 {
-label Sill
}
GuidoField sill0 {
-display_length 10
-format double
-max_length 20
-next_focus range0
-tip "Enter the sill for this variogram structure."
-translate upper
}
GuidoField sill1 {
-display_length 10
-format double
-max_length 20
-next_focus range1
-tip "Enter the sill for this variogram structure."
-translate upper
}
GuidoField sill2 {
-display_length 10
-format double
-max_length 20
-next_focus range2
-tip "Enter the sill for this variogram structure."
-translate upper
}
GuidoField sill3 {
-display_length 10
-format double
-max_length 20
-next_focus range3
-tip "Enter the sill for this variogram structure."
-translate upper
}
GuidoField sill4 {
-display_length 10
-format double
-max_length 20
-next_focus range4
-tip "Enter the sill for this variogram structure."
-translate upper
}
}
GuidoFiller frm00676_18 {
-width 1
}
GuidoPanel frm00676_15 {
-layout BoxLayout Y_AXIS
GuidoLabel frm00676_4 {
-label Range
}
GuidoField range0 {
-display_length 10
-format double
-max_length 20
-next_focus sill1
-tip "Enter the range for this variogram structure."
-translate upper
}
GuidoField range1 {
-display_length 10
-format double
-max_length 20
-next_focus sill2
-tip "Enter the range for this variogram structure."
-translate upper
}
GuidoField range2 {
-display_length 10
-format double
-max_length 20
-next_focus sill3
-tip "Enter the range for this variogram structure."
-translate upper
}
GuidoField range3 {
-display_length 10
-format double
-max_length 20
-next_focus sill4
-tip "Enter the range for this variogram structure."
-translate upper
}
GuidoField range4 {
-display_length 10
-format double
-max_length 20
-tip "Enter the range for this variogram structure."
-translate upper
}
}
GuidoFiller frm00676_18 {
-width 1
}
}
GuidoFiller frm00676_19 {
-height 1
}
GuidoPanel frm00676_20 {
-layout CentreLineLayout
GuidoCheckBox constrain {
-default false
-label "Constrain interpolation?"
-selected_value Y
-tip "00673_TIP_2"
-unselected_value N
}
}
}
