Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
plotID_matlab
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Model registry
Monitor
Service Desk
Analyze
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
plotID
plotID_matlab
Commits
ae012aaf
Commit
ae012aaf
authored
3 years ago
by
Lemmer, Jan
Browse files
Options
Downloads
Patches
Plain Diff
Correct some spelling, Add some comments
parent
e03b00a9
No related branches found
No related tags found
2 merge requests
!13
PreRelease_V0.1
,
!12
PreRelease_V0.1
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
example.m
+6
-8
6 additions, 8 deletions
example.m
fcn_core/CreateID.m
+3
-2
3 additions, 2 deletions
fcn_core/CreateID.m
fcn_core/Publish.m
+7
-7
7 additions, 7 deletions
fcn_core/Publish.m
fcn_core/TagPlot.m
+1
-1
1 addition, 1 deletion
fcn_core/TagPlot.m
with
17 additions
and
18 deletions
example.m
+
6
−
8
View file @
ae012aaf
...
@@ -44,6 +44,11 @@ h5create(fpath, "/y1", size(y1), "Datatype", class(y1))
...
@@ -44,6 +44,11 @@ h5create(fpath, "/y1", size(y1), "Datatype", class(y1))
h5write
(
fpath
,
"/x1"
,
x1
)
h5write
(
fpath
,
"/x1"
,
x1
)
h5write
(
fpath
,
"/y1"
,
y1
)
h5write
(
fpath
,
"/y1"
,
y1
)
%% function calls
% Place for post-processing of the data, or additional related code.
a
=
1
;
% example_fcn is a dummy function to show the functionality
a
=
example_fcn
(
a
);
%% Plotting
%% Plotting
% This is still part of a normal script to produce plots.
% This is still part of a normal script to produce plots.
...
@@ -60,16 +65,10 @@ set(gca, 'TickDir', 'out', 'YLim', [0,4]);
...
@@ -60,16 +65,10 @@ set(gca, 'TickDir', 'out', 'YLim', [0,4]);
%% Tag the plot
%% Tag the plot
% PlotID Implementation starts here.
% PlotID Implementation starts here.
% TagPlot adds a visible ID to the figure and to the property fig.Tag
[
figs
,
ID
]
=
TagPlot
(
fig
,
ProjectID
);
[
figs
,
ID
]
=
TagPlot
(
fig
,
ProjectID
);
%% call a dummy function
% Place for post-processing of the plot, or additional related code.
a
=
1
;
a
=
example_fcn
(
a
);
%% Publishing
%% Publishing
% Second part of plotID
% Second part of plotID
% The functions needs the file location, the location of the data and the
% The functions needs the file location, the location of the data and the
...
@@ -83,7 +82,6 @@ path.rdata = {dataset1,dataset2} ; % don't forget the extension
...
@@ -83,7 +82,6 @@ path.rdata = {dataset1,dataset2} ; % don't forget the extension
Publish
(
path
,
ID
,
figs
,
'Location'
,
'local'
,
'Method'
,
'centraliced'
)
Publish
(
path
,
ID
,
figs
,
'Location'
,
'local'
,
'Method'
,
'centraliced'
)
%% Second Plot with identical data to test centralized method
%% Second Plot with identical data to test centralized method
%
fig2
=
figure
;
fig2
=
figure
;
plot
(
x
,
y
,
'-k'
);
plot
(
x
,
y
,
'-k'
);
...
...
This diff is collapsed.
Click to expand it.
fcn_core/CreateID.m
+
3
−
2
View file @
ae012aaf
function
[
ID
]
=
CreateID
(
method
)
function
[
ID
]
=
CreateID
(
method
)
%CreateID Creates an
I
dentifier (char)
%CreateID Creates an
i
dentifier (char)
% Creates an (sometimes unique) identifier based on the selected method
% Creates an (sometimes unique) identifier based on the selected method
% if no method is selected method 1 will be the default method
% if no method is selected method 1 will be the default method
arguments
arguments
...
@@ -13,7 +13,8 @@ switch method
...
@@ -13,7 +13,8 @@ switch method
pause
(
0.5
);
%Pausing for unique IDs
pause
(
0.5
);
%Pausing for unique IDs
case
2
% random UUID from Java 128 bit
case
2
% random UUID from Java 128 bit
%Static factory to retrieve a type 4 (pseudo randomly generated) UUID.
%Static factory to retrieve a type 4 (pseudo randomly generated) UUID.
% The UUID is generated using a cryptographically strong pseudo random number generator.
% The UUID is generated using a cryptographically strong pseudo
% random number generator.
temp
=
java
.
util
.
UUID
.
randomUUID
;
temp
=
java
.
util
.
UUID
.
randomUUID
;
ID
=
temp
.
toString
;
ID
=
temp
.
toString
;
otherwise
otherwise
...
...
This diff is collapsed.
Click to expand it.
fcn_core/Publish.m
+
7
−
7
View file @
ae012aaf
function
Publish
(
DataPaths
,
ID
,
figures
,
options
)
function
Publish
(
DataPaths
,
ID
,
figures
,
options
)
%Publishes
S
aves
P
lot,
D
ata and
M
easuring script
%Publishes
s
aves
p
lot,
d
ata and
m
easuring script
%
Detailed explanation goe
s he
re
%
Location sets the storage location. 'local' set
s
t
he
storage location
%
Location sets the storage location. local is in the current folder (an
%
to the current folder (an export folder will be created), 'server' is a
%
export folder will be created), server is a
remote
P
ath
% remote
p
ath
.
%
t
wo Methods are implemented individual stores the data for
each plot
%
T
wo Methods are implemented
'
individual
'
stores the data for
% while centralized uses a data folder and uses reference links
to the
%
each plot
while
'
centralized
'
uses a data folder and uses reference links
% original data
%
to the
original data
(hdf5 only).
arguments
arguments
DataPaths
DataPaths
...
...
This diff is collapsed.
Click to expand it.
fcn_core/TagPlot.m
+
1
−
1
View file @
ae012aaf
function
[
figs
,
ID
]
=
TagPlot
(
figs
,
prefix
,
options
)
function
[
figs
,
ID
]
=
TagPlot
(
figs
,
prefix
,
options
)
%TagPlot adds IDs to figures
%TagPlot adds IDs to figures
% The ID is placed visual on the figure window and as Tag (
P
roperty of figure)
% The ID is placed visual on the figure window and as Tag (
p
roperty of figure)
% TagPlot can tag multiple figures at once
% TagPlot can tag multiple figures at once
% prefix is the project number (string or char)
% prefix is the project number (string or char)
%
%
...
...
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