File tree 11 files changed +449
-100
lines changed 11 files changed +449
-100
lines changed Original file line number Diff line number Diff line change @@ -6,3 +6,4 @@ version = "0.1.0"
6
6
[deps ]
7
7
DataFrames = " a93c6f00-e57d-5684-b7b6-d8193f3e46c0"
8
8
Statistics = " 10745b16-79ce-11e8-11f9-7d13ad32a3b2"
9
+ Test = " 8dfed614-e22c-5e08-85e1-65c5234f0b40"
Original file line number Diff line number Diff line change 6
6
[ ![ Codecov] ( https://codecov.io/gh/eco-hydro/VegSeasons.jl/branch/master/graph/badge.svg )] ( https://codecov.io/gh/eco-hydro/VegSeasons.jl/tree/master )
7
7
8
8
> Dongdong Kong
9
+
10
+
11
+ ## References
12
+
13
+
14
+ - ` Findpeaks.jl ` : < https://github.com/tungli/Findpeaks.jl >
15
+
16
+ - ` Peaks.jl ` : < https://github.com/halleysfifthinc/Peaks.jl >
17
+
18
+ - < https://github.com/halleysfifthinc/Peaks.jl/issues/11#issuecomment-689998279 >
Load Diff This file was deleted.
Original file line number Diff line number Diff line change
1
+ ignore :
2
+ - " src/back/*"
3
+ - " src/*/deprecated"
4
+ - " src/temp/*"
5
+ - " src/*/temp"
6
+ - " src/findpeaks_allen.jl"
File renamed without changes.
Original file line number Diff line number Diff line change
1
+ 301.12555 372.666656494
2
+ 301.13156 379.666656494
3
+ 301.13754 360.333312988
4
+ 301.14352 382.0
5
+ 301.14954 369.0
6
+ 301.15552 368.0
7
+ 301.16153 373.333312988
8
+ 301.16751 369.333312988
9
+ 301.17349 382.0
10
+ 301.1795 377.0
11
+ 301.18549 357.333312988
12
+ 301.19147 348.333312988
13
+ 301.19748 355.333312988
14
+ 301.20346 374.333312988
15
+ 301.20947 369.666656494
16
+ 301.21545 364.333312988
17
+ 301.22144 351.0
18
+ 301.22745 339.0
19
+ 301.23343 352.666656494
20
+ 301.23941 354.666656494
21
+ 301.24542 360.0
22
+ 301.2514 368.0
23
+ 301.25739 344.666656494
24
+ 301.2634 394.333312988
25
+ 301.26938 408.333312988
26
+ 301.27536 399.333312988
27
+ 301.28134 421.666656494
28
+ 301.28735 490.333312988
29
+ 301.29333 619.333312988
30
+ 301.29932 607.666656494
31
+ 301.30533 498.333312988
32
+ 301.31131 386.666656494
33
+ 301.31729 388.333312988
34
+ 301.32327 385.666656494
35
+ 301.32928 374.666656494
36
+ 301.33527 330.666656494
37
+ 301.34125 368.333312988
38
+ 301.34726 387.333312988
39
+ 301.35324 375.333312988
40
+ 301.35922 377.0
41
+ 301.3652 354.0
42
+ 301.37122 379.0
43
+ 301.3772 368.0
44
+ 301.38318 338.666656494
45
+ 301.38916 363.0
46
+ 301.39517 348.666656494
47
+ 301.40115 382.0
48
+ 301.40714 358.333312988
49
+ 301.41312 365.0
50
+ 301.4191 396.666656494
51
+ 301.42511 365.666656494
52
+ 301.43109 369.666656494
53
+ 301.43707 369.0
54
+ 301.44305 367.666656494
55
+ 301.44907 384.666656494
56
+ 301.45505 350.666656494
57
+ 301.46103 359.0
58
+ 301.46701 381.0
59
+ 301.47299 378.333312988
60
+ 301.47897 357.0
61
+ 301.48499 357.333312988
62
+ 301.49097 369.333312988
63
+ 301.49695 353.666656494
64
+ 301.50293 351.666656494
65
+ 301.50891 380.333312988
66
+ 301.51489 366.666656494
67
+ 301.5209 338.333312988
68
+ 301.52689 371.666656494
69
+ 301.53287 376.333312988
70
+ 301.53885 362.666656494
71
+ 301.54483 338.666656494
72
+ 301.55081 371.0
73
+ 301.55682 345.666656494
74
+ 301.56281 389.0
75
+ 301.56879 396.0
76
+ 301.57477 352.0
77
+ 301.58075 373.333312988
78
+ 301.58673 382.666656494
79
+ 301.59271 367.0
80
+ 301.59869 343.333312988
81
+ 301.60468 370.666656494
82
+ 301.61069 361.666656494
83
+ 301.61667 372.666656494
84
+ 301.62265 386.666656494
85
+ 301.62863 338.666656494
86
+ 301.63461 367.0
87
+ 301.64059 371.666656494
88
+ 301.64658 363.333312988
89
+ 301.65256 362.0
90
+ 301.65854 357.333312988
91
+ 301.66452 379.666656494
92
+ 301.6705 369.333312988
93
+ 301.67648 394.0
94
+ 301.6825 382.333312988
95
+ 301.68848 370.666656494
96
+ 301.69446 360.0
97
+ 301.70044 377.333312988
98
+ 301.70642 391.333312988
99
+ 301.7124 382.333312988
100
+ 301.71838 352.333312988
101
+ 301.72437 354.0
102
+ 301.73035 363.0
103
+ 301.73633 407.333312988
104
+ 301.74231 410.333312988
105
+ 301.74829 413.0
106
+ 301.75427 447.666656494
107
+ 301.76025 525.0
108
+ 301.76624 757.333312988
109
+ 301.77222 913.333312988
110
+ 301.7782 679.333312988
111
+ 301.78418 474.333312988
112
+ 301.79016 399.0
113
+ 301.79614 369.666656494
114
+ 301.80212 375.666656494
115
+ 301.80811 352.666656494
116
+ 301.81409 348.333312988
117
+ 301.82007 375.333312988
118
+ 301.82605 383.666656494
119
+ 301.83203 390.333312988
120
+ 301.83801 371.666656494
121
+ 301.84399 360.666656494
122
+ 301.84998 375.333312988
123
+ 301.85596 372.0
124
+ 301.86194 363.0
125
+ 301.86789 374.666656494
126
+ 301.87387 350.0
127
+ 301.87985 362.666656494
128
+ 301.88583 365.333312988
129
+ 301.89182 370.333312988
130
+ 301.8978 373.666656494
131
+ 301.90378 389.0
132
+ 301.90976 394.666656494
133
+ 301.91574 375.0
134
+ 301.92172 373.666656494
135
+ 301.9277 348.0
136
+ 301.93369 375.333312988
137
+ 301.93964 376.666656494
138
+ 301.94562 375.666656494
139
+ 301.9516 364.333312988
140
+ 301.95758 384.333312988
141
+ 301.96356 369.0
142
+ 301.96954 366.666656494
143
+ 301.97552 370.666656494
144
+ 301.98151 365.666656494
145
+ 301.98746 367.333312988
146
+ 301.99344 380.0
147
+ 301.99942 372.333312988
148
+ 302.0054 387.333312988
149
+ 302.01138 381.0
150
+ 302.01736 367.666656494
151
+ 302.02335 373.666656494
152
+ 302.0293 386.0
153
+ 302.03528 369.333312988
154
+ 302.04126 364.666656494
155
+ 302.04724 378.0
156
+ 302.05322 379.666656494
157
+ 302.0592 391.333312988
158
+ 302.06516 377.0
159
+ 302.07114 373.666656494
160
+ 302.07712 362.0
161
+ 302.0831 395.666656494
162
+ 302.08908 393.333312988
163
+ 302.09503 392.333312988
164
+ 302.10101 374.0
165
+ 302.10699 379.333312988
166
+ 302.11298 352.0
167
+ 302.11896 402.333312988
168
+ 302.12491 403.0
169
+ 302.13089 383.0
170
+ 302.13687 381.666656494
171
+ 302.14285 389.0
172
+ 302.1488 400.0
173
+ 302.15479 373.0
174
+ 302.16077 375.333312988
175
+ 302.16675 368.666656494
176
+ 302.17273 392.666656494
177
+ 302.17868 378.666656494
178
+ 302.18466 369.333312988
179
+ 302.19064 370.333312988
180
+ 302.19659 363.666656494
181
+ 302.20258 387.0
182
+ 302.20856 402.333312988
183
+ 302.21454 361.333312988
184
+ 302.22049 397.666656494
185
+ 302.22647 407.333312988
186
+ 302.23245 435.333312988
187
+ 302.23843 452.666656494
188
+ 302.24438 469.0
189
+ 302.25037 607.0
190
+ 302.25635 918.0
191
+ 302.2623 930.333312988
192
+ 302.26828 658.666656494
193
+ 302.27426 471.0
194
+ 302.28021 389.0
195
+ 302.28619 391.666656494
196
+ 302.29218 375.0
197
+ 302.29813 381.333312988
198
+ 302.30411 392.666656494
199
+ 302.31009 376.666656494
200
+ 302.31604 362.666656494
201
+ 302.32202 391.666656494
202
+ 302.328 380.333312988
203
+ 302.33395 422.0
204
+ 302.33994 381.333312988
205
+ 302.34592 420.333312988
206
+ 302.35187 488.666656494
207
+ 302.35785 577.333312988
208
+ 302.36383 710.333312988
209
+ 302.36978 721.666656494
210
+ 302.37576 814.666656494
211
+ 302.38171 1005.333312988
212
+ 302.3877 844.0
213
+ 302.39368 594.333312988
214
+ 302.39963 511.0
215
+ 302.40561 513.0
216
+ 302.41156 529.0
217
+ 302.41754 551.0
218
+ 302.42352 684.666656494
219
+ 302.42947 966.666656494
220
+ 302.43546 955.666656494
221
+ 302.44141 709.333312988
222
+ 302.44739 529.666656494
223
+ 302.45337 459.0
224
+ 302.45932 441.333312988
225
+ 302.4653 417.333312988
226
+ 302.47125 422.0
227
+ 302.47723 440.666656494
228
+ 302.48318 471.0
229
+ 302.48917 502.0
230
+ 302.49512 560.333312988
231
+ 302.5011 874.0
232
+ 302.50708 1121.666656494
233
+ 302.51303 958.333312988
234
+ 302.51901 942.666656494
235
+ 302.52496 839.666656494
236
+ 302.53094 600.0
237
+ 302.5369 470.0
238
+ 302.54288 440.333312988
239
+ 302.54883 419.0
240
+ 302.55481 411.666656494
241
+ 302.56076 420.0
242
+ 302.56674 409.0
243
+ 302.57269 413.0
244
+ 302.57867 504.0
245
+ 302.58463 511.0
246
+ 302.59061 585.666656494
247
+ 302.59656 694.666656494
248
+ 302.60254 1023.333312988
249
+ 302.60849 1824.0
250
+ 302.61447 1838.0
251
+ 302.62042 1314.333312988
252
+ 302.6264 1046.333312988
253
+ 302.63235 691.666656494
254
+ 302.63831 641.666656494
255
+ 302.64429 655.0
256
+ 302.65024 640.333312988
257
+ 302.65622 488.333312988
258
+ 302.66217 419.666656494
259
+ 302.66815 395.333312988
260
+ 302.6741 404.0
261
+ 302.68008 396.333312988
262
+ 302.68604 420.666656494
263
+ 302.69199 437.0
264
+ 302.69797 442.0
265
+ 302.70392 523.333312988
266
+ 302.7099 615.0
267
+ 302.71585 737.333312988
268
+ 302.7218 867.666656494
269
+ 302.72778 1214.666656494
270
+ 302.73373 2404.0
271
+ 302.73972 3620.333312988
272
+ 302.74567 2985.666656494
273
+ 302.75162 2194.666656494
274
+ 302.7576 1377.0
275
+ 302.76355 795.0
276
+ 302.76953 599.666656494
277
+ 302.77548 670.333312988
278
+ 302.78143 835.666656494
279
+ 302.78741 861.0
280
+ 302.79337 866.0
281
+ 302.79932 792.333312988
282
+ 302.8053 895.666656494
283
+ 302.81125 959.333312988
284
+ 302.8172 747.0
285
+ 302.82318 563.0
286
+ 302.82913 520.0
287
+ 302.83508 504.333312988
288
+ 302.84106 605.0
289
+ 302.84702 696.666656494
290
+ 302.85297 761.666656494
291
+ 302.85895 862.0
292
+ 302.8649 1013.666656494
293
+ 302.87085 1316.0
294
+ 302.87683 2119.0
295
+ 302.88278 4045.666656494
296
+ 302.88873 6054.666656494
297
+ 302.89468 5485.0
298
+ 302.90067 3806.333312988
299
+ 302.90662 1878.666656494
300
+ 302.91257 918.0
Original file line number Diff line number Diff line change
1
+ @time using DelimitedFiles
2
+ using BenchmarkTools
3
+ data = readdlm (" data/example_spectrum.txt" )
4
+ x = data[:, 1 ]
5
+ y = data[:, 2 ]
6
+
7
+
8
+ @btime raw = findpeaks ($ y);
9
+ @btime d2 = findpeaks_allen ($ y, $ x);
10
+
11
+ d_peaks = filter_peaks (raw,
12
+ A_min= 50 , minpeakheight= 500 , minpeakdistance= 20 )
13
+
14
+ # filter_peaks(df_peaks::DataFrame;
15
+ # minpeakheight=-Inf, minpeakdistance::Int=1,
16
+ # A_max=0, A_min=0
17
+
18
+ begin
19
+ using Plots
20
+ gr (framestyle= :box )
21
+
22
+ # plot(x, y)
23
+ plot (y)
24
+ scatter! (d_peaks. pos_peak, d_peaks. val_peak,
25
+ markersize= 3 ,
26
+ markerstrokewidth= 1 ,
27
+ markerstrokecolor= :white ,
28
+ label= " Peak" ,
29
+ markercolor= :red ,
30
+ markershape= :circle )
31
+
32
+ spans = [d_peaks. pos_beg d_peaks. pos_end]
33
+ val_spans = (spans' )[:]
34
+ vspan! (val_spans; alpha= 0.2 , label= " Seasons" , color= :red )
35
+ end
Original file line number Diff line number Diff line change @@ -8,7 +8,7 @@ using Statistics: quantile
8
8
using RTableTools
9
9
10
10
# pwd()
11
- df = fread("data-raw /02475000.csv")
11
+ df = fread("data/02475000.csv")
12
12
```
13
13
14
14
# findpeaks
You can’t perform that action at this time.
0 commit comments