Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
TSG QC
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
US191
TSG QC
Commits
24981b34
Commit
24981b34
authored
15 years ago
by
Yves Gouriou
Browse files
Options
Downloads
Patches
Plain Diff
La valeur du test de vitesse se fait maintenant via un uicontrol EDIT dans le menu PREFERENCE
parent
71a67336
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
tsg_util/minSpeedQC.m
+23
-19
23 additions, 19 deletions
tsg_util/minSpeedQC.m
tsg_util/preferencesForm.m
+7
-12
7 additions, 12 deletions
tsg_util/preferencesForm.m
tsg_util/tsg_preferences.m
+1
-2
1 addition, 2 deletions
tsg_util/tsg_preferences.m
tsgqc.m
+3
-3
3 additions, 3 deletions
tsgqc.m
with
34 additions
and
36 deletions
tsg_util/minSpeedQC.m
+
23
−
19
View file @
24981b34
...
...
@@ -9,8 +9,6 @@ function minSpeedQC(hMainFig)
%
% problem: the QC flag counter in 'Validation Codes' window
% is not updated after the test is applied
%
% Get the data from the application GUI
% -------------------------------------
...
...
@@ -20,27 +18,33 @@ tsg = getappdata( hMainFig, 'tsg_data');
% ----------------------
harbourCode
=
tsg
.
qc
.
hash
.
HARBOUR
.
code
;
% get preference choice for ship speed test
% -----------------------------------------
test
=
tsg
.
preference
.
ship_speed_test
;
speed_min
=
tsg
.
preference
.
ship_speed_min_string
;
if
(
test
==
2
)
% If necessary replace a comma by a point
% ---------------------------------------
speed_min
=
regexprep
(
speed_min
,
','
,
'.'
);
speed_min_string
=
tsg
.
preference
.
ship_speed_min_string
;
speed_min_choice
=
tsg
.
preference
.
ship_speed_min
;
speed_min
=
str2double
(
speed_min
_string
(
speed_min_choice
)
);
% If bias not a numeric, str2double return a NaN
% ----------------------------------------------
speed_min
=
str2double
(
speed_min
);
% Set salinity QC to HARBOUR for ship speed < speed_min
% -----------------------------------------------------
ind
=
find
(
tsg
.
SPDC
<
speed_min
);
if
~
isempty
(
ind
)
tsg
.
SSPS_QC
(
ind
)
=
castByteQC
(
harbourCode
,
ind
);
end
if
isnumeric
(
speed_min
)
&&
~
isnan
(
speed_min
)
end
% Set salinity QC to BAD for flow < flow_min
% -----------------------------------------------------
ind
=
find
(
tsg
.
SPDC
<
speed_min
);
if
~
isempty
(
ind
)
tsg
.
SSPS_QC
(
ind
)
=
castByteQC
(
harbourCode
,
ind
);
end
% Save tsg structure
% ------------------
setappdata
(
hMainFig
,
'tsg_data'
,
tsg
);
% Save tsg structure
% ------------------
setappdata
(
hMainFig
,
'tsg_data'
,
tsg
);
else
msgbox
(
'Enter a numeric value in the REFERENCE menu'
,
'Speed QC'
,
...
'error'
,
'modal'
);
end
end
This diff is collapsed.
Click to expand it.
tsg_util/preferencesForm.m
+
7
−
12
View file @
24981b34
...
...
@@ -271,25 +271,20 @@ end
uicontrol
(
...
'Parent'
,
hPreferencesFig
,
...
'Units'
,
'normalized'
,
...
'Style'
,
'Text'
,
...
'Fontsize'
,
tsg
.
fontSize
-
1
,
...
'HorizontalAlignment'
,
'left'
,
...
'Style'
,
'Text'
,
'Fontsize'
,
tsg
.
fontSize
-
1
,
'HorizontalAlignment'
,
'left'
,
...
'Position'
,[
left
,
bottom
,
length
,
height
],
...
'TooltipString'
,
'
s
elect ship speed min (knots)'
,
...
'TooltipString'
,
'
S
elect ship speed min (knots)'
,
...
'String'
,
'Ship Speed Min (knots)'
);
% display ship speed min uicontrol
% --------------------------------
uicontrol
(
...
'Parent'
,
hPreferencesFig
,
...
'Units'
,
'normalized'
,
...
'BackgroundColor'
,
'w'
,
...
'Style'
,
'popupmenu'
,
...
'Fontsize'
,
tsg
.
fontSize
-
2
,
...
'HorizontalAlignment'
,
'right'
,
...
'Units'
,
'normalized'
,
'Style'
,
'Edit'
,
'BackgroundColor'
,
'w'
,
...
'Fontsize'
,
tsg
.
fontSize
-
2
,
'HorizontalAlignment'
,
'right'
,
...
'Position'
,
[
left
+
length
,
bottom
,
length
,
height
],
...
'String'
,
tsg
.
preference
.
ship_speed_min_string
,
...
'Value'
,
tsg
.
preference
.
ship_speed_min
,
'Tag'
,
'PREFERENCES_SHIP_SPEED_MIN'
);
'Tag'
,
'PREFERENCES_SHIP_SPEED_MIN'
);
bottom
=
bottom
-
inc_y
-
height
;
if
bottom
<
.
1
...
...
@@ -519,8 +514,8 @@ uiwait(hPreferencesFig);
get
(
prefs
.
PREFERENCES_FLOW_MIN
,
'string'
);
tsg
.
preference
.
press_min_string
=
...
get
(
prefs
.
PREFERENCES_PRESS_MIN
,
'string'
);
tsg
.
preference
.
ship_speed_min
=
...
get
(
prefs
.
PREFERENCES_SHIP_SPEED_MIN
,
'
value
'
);
tsg
.
preference
.
ship_speed_min
_string
=
...
get
(
prefs
.
PREFERENCES_SHIP_SPEED_MIN
,
'
string
'
);
tsg
.
preference
.
ssps_min_string
=
...
get
(
prefs
.
PREFERENCES_SSPS_MIN
,
'string'
);
tsg
.
preference
.
ssps_max_string
=
...
...
...
This diff is collapsed.
Click to expand it.
tsg_util/tsg_preferences.m
+
1
−
2
View file @
24981b34
...
...
@@ -146,8 +146,7 @@ end
% QC test
preference
.
flow_min_string
=
{
'1'
};
preference
.
press_min_string
=
{
'1'
};
preference
.
ship_speed_min_string
=
{
'1'
,
'3'
,
'5'
};
preference
.
ship_speed_min
=
1
;
preference
.
ship_speed_min_string
=
{
'1'
};
preference
.
ssps_min_string
=
{
'0'
};
preference
.
ssps_max_string
=
{
'50'
};
preference
.
sstp_min_string
=
{
'-3'
};
...
...
This diff is collapsed.
Click to expand it.
tsgqc.m
+
3
−
3
View file @
24981b34
...
...
@@ -36,8 +36,8 @@ global NETCDF_FORMAT_VERSION
% version number, may be used to initialize some files when it change
% 0.90x -> 1.0RCx
% -------------------------------------------------------------------
VERSION
=
1.0
2
;
% -> 1.0
2
CHAR_VERSION
=
'1.0
2
'
;
VERSION
=
1.0
3
;
% -> 1.0
3
CHAR_VERSION
=
'1.0
3
'
;
% netcdf file version, see DATA FORMAT TSG document:
% CORTSG_format_gosud_1.5.doc
...
...
@@ -276,7 +276,7 @@ hQCMenu = uimenu(...
'Label'
,
'QCauto'
);
hFlowMenu
=
uimenu
(
...
'Parent'
,
hQCMenu
,
'Label'
,
'Flow'
,
'HandleVisibility'
,
handleVisibility
,
...
'UserData'
,
'off'
,
'Enable'
,
'off'
,
'Callback'
,
{
@
QCMenuCallback
,
'Flow'
});
'UserData'
,
'off'
,
'Callback'
,
{
@
QCMenuCallback
,
'Flow'
});
hPressMenu
=
uimenu
(
...
'Parent'
,
hQCMenu
,
'Label'
,
'Press'
,
'HandleVisibility'
,
handleVisibility
,
...
'UserData'
,
'off'
,
'Callback'
,
{
@
QCMenuCallback
,
'Press'
});
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment