Learn R Programming

madrat (version 3.15.6)

downloadSource: downloadSource

Description

Download a source. The function is a wrapper for specific functions designed for the different possible source types.

Usage

downloadSource(type, subtype = NULL, overwrite = FALSE, numberOfTries = 300)

Arguments

type

source type, e.g. "IEA". A list of all available source types can be retrieved with function getSources("download").

subtype

For some sources there are subtypes of the source, for these source the subtype can be specified with this argument. If a source does not have subtypes, subtypes should not be set.

overwrite

Boolean deciding whether existing data should be overwritten or not.

numberOfTries

Integer determining how often readSource will check whether a running download is finished before exiting with an error. Between checks readSource will wait 30 seconds. Has no effect if the sources that should be read are not currently being downloaded.

Author

Jan Philipp Dietrich, David Klein, Pascal Sauer

See Also

setConfig, readSource

Examples

Run this code
if (FALSE) {
a <- downloadSource("Tau", subtype = "historical")
}

Run the code above in your browser using DataLab