Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
CRP Toolbox for MATLAB
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
Container 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
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Norbert Marwan
CRP Toolbox for MATLAB
Commits
065fee75
Commit
065fee75
authored
19 years ago
by
marwan
Browse files
Options
Downloads
Patches
Plain Diff
plugin added
parent
d2dd2dc5
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
private/crp_plugin.m
+84
-0
84 additions, 0 deletions
private/crp_plugin.m
private/is_crp_plugin.m
+34
-0
34 additions, 0 deletions
private/is_crp_plugin.m
with
118 additions
and
0 deletions
private/crp_plugin.m
0 → 100644
+
84
−
0
View file @
065fee75
function
[
X
,
matext
]
=
crp_plugin
(
x
,
y
,
m
,
t
,
e
,
mflag
,
hCRP
,
plugin_path
,
silent
)
% CRP_PLUGIN Loads and executes the extern plugin
% Used by CRP Toolbox
% Copyright (c) 2005 by AMRON
% Norbert Marwan, Potsdam University, Germany
% http://www.agnld.uni-potsdam.de
%
% $Date$
% $Revision$
%
% $Log$
%
%
% This program is free software; you can redistribute it and/or
% modify it under the terms of the GNU General Public License
% as published by the Free Software Foundation; either version 2
% of the License, or any later version.
global
errcode
X
=
[];
matext
=
''
;
try
tmp_xdatafile
=
tempname
;
tmp_ydatafile
=
tempname
;
tmp_rpdatafile
=
tempname
;
if
~
silent
,
set
(
findobj
(
'Tag'
,
'Status'
,
'Parent'
,
findobj
(
'Parent'
,
hCRP
,
'Tag'
,
'CRPPlot'
)),
'String'
,
'Export Data'
),
drawnow
,
end
save
(
tmp_xdatafile
,
'x'
,
'-ascii'
,
'-tabs'
);
save
(
tmp_ydatafile
,
'y'
,
'-ascii'
,
'-tabs'
);
% call extern rp programme
if
~
silent
,
set
(
findobj
(
'Tag'
,
'Status'
,
'Parent'
,
findobj
(
'Parent'
,
hCRP
,
'Tag'
,
'CRPPlot'
)),
'String'
,
'Compute Recurrence Points'
),
drawnow
,
end
m_str
=
{
'MAX'
,
'EUC'
,
'MIN'
,
''
,
''
,
''
,
''
,
''
,
'EUC'
};
dis_sign
=
1
;
if
mflag
==
9
,
dis_sign
=
-
1
;
end
system
([
plugin_path
,
filesep
,
'rp -m '
,
num2str
(
1
),
...
' -t '
,
num2str
(
1
),
...
' -e '
,
num2str
(
dis_sign
*
e
),
...
' -n '
,
m_str
{
mflag
},
...
' -w '
,
num2str
(
0
),
...
' -i '
,
tmp_xdatafile
,
...
' -j '
,
tmp_ydatafile
,
...
' -r '
,
tmp_rpdatafile
,
...
' -f TIF'
,
...
' -s'
]);
% import rp
if
~
silent
,
set
(
findobj
(
'Tag'
,
'Status'
,
'Parent'
,
findobj
(
'Parent'
,
hCRP
,
'Tag'
,
'CRPPlot'
)),
'String'
,
'Import Recurrence Points'
),
drawnow
,
end
X
=
imread
(
tmp_rpdatafile
);
X
=
(
double
(
X
)/
65535
);
delete
(
tmp_rpdatafile
);
delete
(
tmp_xdatafile
);
delete
(
tmp_ydatafile
);
if
~
silent
,
set
(
findobj
(
'Tag'
,
'Status'
,
'Parent'
,
findobj
(
'Parent'
,
hCRP
,
'Tag'
,
'CRPPlot'
)),
'String'
,
'Plot Recurrence Points'
),
drawnow
,
end
switch
mflag
case
1
%%%%%%%%%%%%%%%%% maximum norm
matext
=
[
num2str
(
round
(
100
*
e
)/
100
)
'\sigma (fixed distance maximum norm)'
];
case
2
%%%%%%%%%%%%%%%%% euclidean norm
errcode
=
112
;
matext
=
[
num2str
(
round
(
100
*
e
)/
100
)
'\sigma (fixed distance euclidean norm)'
];
case
3
%%%%%%%%%%%%%%%%% minimum norm
errcode
=
113
;
matext
=
[
num2str
(
round
(
100
*
e
)/
100
)
'\sigma (fixed distance minimum norm)'
];
%%%%%%%%%%%%%%%%% global RP
case
9
X
=
X
*
(
max
([
max
(
x
),
max
(
y
)])
-
min
([
min
(
x
),
min
(
y
)])
);
matext
=
''
;
end
catch
warning
off
delete
(
tmp_rpdatafile
);
delete
(
tmp_xdatafile
);
delete
(
tmp_ydatafile
);
warning
on
end
This diff is collapsed.
Click to expand it.
private/is_crp_plugin.m
0 → 100644
+
34
−
0
View file @
065fee75
function
[
plugin_exist
,
plugin_path
]
=
is_crp_plugin
% IS_CRP_PLUGIN Checks if extern plugin exist and is executable
% Used by CRP Toolbox
% Copyright (c) 2005 by AMRON
% Norbert Marwan, Potsdam University, Germany
% http://www.agnld.uni-potsdam.de
%
% $Date$
% $Revision$
%
% $Log$
%
%
% This program is free software; you can redistribute it and/or
% modify it under the terms of the GNU General Public License
% as published by the Free Software Foundation; either version 2
% of the License, or any later version.
global
errcode
plugin_exist
=
0
;
plugin_path
=
''
;
if
exist
(
'rp'
,
'file'
)
plugin_exist
=
0
;
plugin_path
=
fileparts
(
which
(
'rp'
));
try
[
status
dummy
]
=
system
([
plugin_path
,
filesep
,
'rp -V > /tmp/1'
]);
catch
status
=
1
;
end
if
~
status
,
plugin_exist
=
1
;
end
end
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