kurtisanstey / internal_waves_barkley_canyon

Ocean Physics MSc thesis at the University of Victoria, under the supervision of Dr. Jody Klymak, characterising the internal wave field at Barkley Canyon.
2 stars 1 forks source link

Temporal data gaps (Axis 55 - 2018/2019) #14

Closed kurtisanstey closed 3 years ago

kurtisanstey commented 3 years ago

Using appropriate averaging and weighting. Trying to automate it so I don't have to do it manually every time I want these years or seasons.

kurtisanstey commented 3 years ago

Doing the windows individually and averaging them myself. This may take a bit, but I'll save the final spectra from each window so I don't have to do it again.

kurtisanstey commented 3 years ago

@jklymak

It's working! I've checked for other years, but this example (Axis 55 kHz 2017) has only one small data gap, so the new process PSD can be reasonably compared with the old method that used interpolated data. I do use a slightly longer nperseg window in the new process, and the interpolated gap is of course absent, but it looks good.

Rough velocities to show data gap: image

Old PSD from interpolated data: image

New PSD from weighted average process: image

I then expanded the segment by segment data approach to the rest of my analysis processes (just finishing up applying it to the rotary spectra), to reduce the amount of overall interpolation that existed in my code. Everything is working nicely:

image image

kurtisanstey commented 3 years ago

@jklymak

kurtisanstey commented 3 years ago

These processes are working.