Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

download.prism

Download PRISM


Description

Batch download of monthly gridded PRISM climate data

Usage

download.prism(
  data.type,
  date.range,
  time.step = "monthly",
  download.folder = c("current", "temp"),
  by.year = FALSE,
  unzip.file = TRUE,
  ftp.site = "ftp://prism.oregonstate.edu"
)

Arguments

data.type

Specify climate metric ('ppt','tmin','tmax','tmean')

date.range

A vector with start and end date in y/m/d format

time.step

Timestep of product ('daily'/'monthly')

download.folder

Local download directory, defaults to current working directory

by.year

Create a directory for each year (TRUE/FALSE)

unzip.file

Unzip file on download (TRUE/FALSE)

ftp.site

PRISM ftp address to use, default: ftp://prism.oregonstate.edu

Details

Monthly data 1895-1980 is available in a single zip file on the ftp site PRISM URL: https://prism.oregonstate.edu/ FTP download sites for 400m gridded daily/monthly climate data ftp://prism.oregonstate.edu/daily ftp://prism.oregonstate.edu/monthly

i.e., 'PRISM_ppt_stable_4kmD1_20100208_bil.zip' Data description: https://prism.oregonstate.edu/documents/PRISM_datasets_aug2013.pdf

Value

Compressed or uncompressed PRISM monthly gridded data(bil raster format)

Author(s)

Jeffrey S. Evans <jeffrey_evans@tnc.org>

Examples

## Not run: 
# Download monthly precipitation data Jan 1st 2000 to Dec 30th 2001 (n=24)
    my.dates <- c('2000/1/1', '2001/12/30')
    download.prism('ppt', date.range=my.dates, time.step='monthly', by.year=TRUE)
 
 # Download monthly precipitation data Jan 1st 2000 to Feb 10th 2000 (n=41)
    my.dates <- c('2000/1/1', '2000/2/10')
    download.prism('ppt', date.range=my.dates, time.step='daily', by.year=TRUE)

## End(Not run)

spatialEco

Spatial Analysis and Modelling Utilities

v1.3-6
GPL-3
Authors
Jeffrey S. Evans [aut, cre], Melanie A. Murphy [ctb], Karthik Ram [ctb]
Initial release
2021-03-24

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.