espa_extract: Extract a set of Landsat tarballs into a folder tree...

Description Usage Arguments Details Value Examples

Description

Each image .tar.gz file will be extracted into a subfolder within output_folder. The subfolders will be named according to the year and Julian date of capture, and the sensor type (LT4, LT5 or LE7 for Landsat 4 TM, Landsat 5 TM, and Landsat 7 ETM+ respectively). For example, "LT50150531986037-SC20130816144215.tar.gz" would be extracted into a subfolder named "1986_037_LT5', for 1986, Julian day 37, and Landsat 5 TM.

Usage

1
2
espa_extract(in_folder, out_folder, pathrows = NULL, start_date = NULL,
  end_date = NULL, sensors = NULL)

Arguments

in_folder

Path to a folder of .tar.gz Landsat surface reflectance images

out_folder

output folder

pathrows

a list of paths/rows to include. Each path/row should be specified as a six digit string. For example, path 231, row 62 would be specified as "231062".

start_date

start date of period from which images will be extracted to (as Date object).

end_date

end date of period from which images will be extracted to (as Date object)

sensors

a list of the sensors to include (can be any of "LT4", "LT5", "LE7", or "LC8")

Details

Zip files for images from sensors not included in sensors, from path/rows not included in pathrows or with acquisition dates outside of the period defined by start_date and end_date will be ignored.

Value

nothing (used for side effect of unzipping Landsat CDR tarballs)

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
## Not run: 
# Don't filter:
espa_extract('D:/Landsat_Originals', 'D:/Landsat_Out')

# Filter by start and end date:
start_date <- as.Date('2010/1/1')
end_date <- as.Date('2010/12/31')
espa_extract('D:/Landsat_Originals', 'D:/Landsat_Out',
             start_date=start_date, end_date=end_date)

# Filter by start and end date, sensor, and pathrow:
espa_extract('D:/Landsat_Originals', 'D:/Landsat_Out', 
             start_date=start_date, end_date=end_date, sensors='LE7',
             pathrows='231062')

## End(Not run)

azvoleff/teamlucc documentation built on May 11, 2019, 5:19 p.m.