Peak Detector.
The algorithm is implemented in detect_peaks.m
- See also
- detect_peaks.m
Definition at line 6 of file peakdetector.m.
|
function | peakdetector (in o) |
|
function | use (in o, in x, in y) |
|
function | boot (in o, in x, in y) |
|
function | get_description (in o, in flag_short) |
|
function | setbatch (in o, in params) |
| Sets several properties of an object at once. More...
|
|
function | get_methodname (in o, in flag_short) |
|
function | get_report (in o) |
| Object reports are plain text. HTML would be cool but c'mon, we don't need that sophistication. More...
|
|
function | get_html (in o, in flag_stylesheet) |
|
function | get_params (in o, in data) |
| Calls Parameters GUI. More...
|
|
function | extract_log (in o) |
|
function | get_ancestry (in o, in flag_title) |
|
|
Property | spacing |
| Horizontal spacing between points, expressed in native units. More...
|
|
Property | minalt |
|
Property | minhei |
|
Property | flag_booted |
|
Property | classtitle |
| Class Title. Should have a descriptive name, as short as possible. More...
|
|
Property | short |
| Short for the method name. More...
|
|
Property | flag_params |
|
Property | flag_ui |
| (GUI setting) Whether to "publish" in blockmenu and datatool. Note that a class can be "published" without a GUI (set flag_params=0 in this case, at the class constructor). More...
|
|
Property | moreactions |
| (GUI setting) String cell containing names of methods that may be called from the GUIs More...
|
|
function peakdetector::peakdetector |
( |
in |
o | ) |
|
function peakdetector::boot |
( |
in |
o, |
|
|
in |
x, |
|
|
in |
y |
|
) |
| |
function irobj::do_get_html |
( |
in |
o | ) |
|
|
protectedinherited |
Abstract. HTML inner body.
function irobj::do_get_report |
( |
in |
o | ) |
|
|
protectedinherited |
function irobj::extract_log |
( |
in |
o | ) |
|
|
inherited |
- Parameters
-
- Returns
- [o, log]
function irobj::get_ancestry |
( |
in |
o, |
|
|
in |
flag_title |
|
) |
| |
|
inherited |
function irobj::get_description |
( |
in |
o, |
|
|
in |
flag_short |
|
) |
| |
|
inherited |
Returns description string
Precedence according with flag_short:
- 0: title > short > classtitle
- 1: short > title > classtitle
- Parameters
-
flag_short=0 | I am sealing this to make sure that no class will try to improvise on this function. |
function irobj::get_html |
( |
in |
o, |
|
|
in |
flag_stylesheet |
|
) |
| |
|
inherited |
- Parameters
-
flag_stylesheet=1 | Whether to include the stylesheet in the HTML |
function irobj::get_methodname |
( |
in |
o, |
|
|
in |
flag_short |
|
) |
| |
|
inherited |
This is used only to compose sequence string e.g. xxx->yyy->zzz
- Parameters
-
function irobj::get_params |
( |
in |
o, |
|
|
in |
data |
|
) |
| |
|
inherited |
Calls Parameters GUI.
If flag_params
, tries uip_<class>.m. If fails, tries uip_<ancestor>.m and so on
function irobj::get_report |
( |
in |
o | ) |
|
|
inherited |
Object reports are plain text. HTML would be cool but c'mon, we don't need that sophistication.
function irobj::setbatch |
( |
in |
o, |
|
|
in |
params |
|
) |
| |
|
inherited |
Sets several properties of an object at once.
- Parameters
-
o | |
params | Cell followint the pattern{'property1', value1, 'property2', value2, ...} |
function peakdetector::use |
( |
in |
o, |
|
|
in |
x, |
|
|
in |
y |
|
) |
| |
Detects peaks
If the peak detector is going to be used many times, it is better to boot it first. Otherwise it will be internally booted every time it is used.
The peak detector will be internally booted when:
x
is not empty, or
the
peak detector hasn't been booted before
- Parameters
-
x | x-axis values. If not empty, the peak detector will be internally booted. |
y | curve to detect peaks from |
Property irobj::classtitle |
|
protectedinherited |
Class Title. Should have a descriptive name, as short as possible.
Definition at line 50 of file irobj.m.
=[0, .8, 0]. multipurpose feature, routines may use it for different things. Major use is to change the background of objtool and blockmenu. See also classes_html.m
Definition at line 42 of file irobj.m.
Property peakdetector::flag_abs |
=1. Whether absolute value of the signal should be used. If 0, negative parts of the signal are made into "lakes", i.e., replaced by zeroes
Definition at line 32 of file peakdetector.m.
Property peakdetector::flag_booted |
|
protected |
Property irobj::flag_params |
|
protectedinherited |
=1. (GUI setting) Whether to call a GUI when the block is selected in blockmenu.m . If true, a routine called "uip_"<class name> will be called.
Definition at line 57 of file irobj.m.
Property peakdetector::flag_perc |
=1. Whether minaltitude and minheight are expressed in percentage. If true, the actual minimum altitude and minimum height will be calculated as a percentage of max(abs(y)).
Definition at line 25 of file peakdetector.m.
(GUI setting) Whether to "publish" in blockmenu and datatool. Note that a class can be "published" without a GUI (set flag_params=0 in this case, at the class constructor).
Definition at line 60 of file irobj.m.
Property peakdetector::minalt |
|
protected |
Property peakdetector::minaltitude |
=0. Minimum vertical distance between peak and zero
Definition at line 12 of file peakdetector.m.
Property peakdetector::mindist |
Minimum distance between peaks, expressed in number of points.
Definition at line 18 of file peakdetector.m.
Property peakdetector::mindist_units |
Minimum distance between peaks, expressed in native units.
Definition at line 21 of file peakdetector.m.
Property peakdetector::minhei |
|
protected |
Property peakdetector::minheight |
=0. Minimum vertical distance between peak and closest trough
Definition at line 15 of file peakdetector.m.
Property irobj::moreactions |
|
protectedinherited |
(GUI setting) String cell containing names of methods that may be called from the GUIs
Definition at line 63 of file irobj.m.
Property peakdetector::no_max |
=Inf. Maximum number of peaks to be returned. If used, peak are returned in ranked order of height.
Definition at line 28 of file peakdetector.m.
Short for the method name.
Definition at line 53 of file irobj.m.
Property peakdetector::spacing |
|
protected |
Horizontal spacing between points, expressed in native units.
Definition at line 38 of file peakdetector.m.
The documentation for this class was generated from the following file: