Getting AVISO FSLE data to then extract FSLE using shark locations and fit mpmm model (similar to Jonsen et al 2019 Ecology).
1) The dataset is huge (130 MB / day) so start with adding a new, temporary volume on AWS. Excellent instructions can be found here.
2) Then get the data like:
for (ii in 1:length(udates)){
yr <- lubridate::year(udates[ii])
mm <- lubridate::month(udates[ii])
if (nchar(mm) == 1) mm <- paste('0', mm, sep='')
dd <- lubridate::day(udates[ii])
if (nchar(dd) == 1) dd <- paste('0', dd, sep='')
url <- paste('ftp://username:password@ftp-access.aviso.altimetry.fr/value-added/lyapunov/delayed-time/global/', yr, '/dt_global_allsat_madt_fsle_', yr, mm, dd, '_20180704.nc', sep='')
out_file <- paste('/home/rstudio/ebs/EnvData/fsle/', 'dt_global_allsat_madt_fsle_', yr, mm, dd, '_20180704.nc', sep='')
download.file(url, out_file)
#system(paste('aws s3 sync . s3://braun-data/EnvData/fsle/'))
#file.remove(out_file)
}
Note that your Aviso account must be “enabled” for FSLE access in order for it to even be visible to you on the FTP site. Make sure you’ve been given access to the dataset if you’re having access issues.
Note if your username is an email address, you need to represent it in the FTP call like cdbraun%40uw.edu, removing the @ character.