getbase.pob: Collects information of population at a municipality level.

Description Usage Arguments Details Value See Also Examples

View source: R/getbase.pob.R

Description

getbase.pob downloads population data of the Spanish municipalities by province.

Usage

1
getbase.pob(year, provincia, extr = FALSE, anual = FALSE)

Arguments

year

a numerical value from 1996 and the latest available, which indicates the year of the required database.

provincia

one of the 52 Spainish province.

extr

logical variable ‘is it foreign population?’ FALSE is the default value.

anual

logical variable ‘is data required by age?’ FALSE is the default value.

Details

The names of the Spanish provinces may or may not be called. If yes, employ capital letters as follows:

"ALBACETE", "ALICANTE", "ALMERIA", "ARABA", "ASTURIAS", "AVILA", "BADAJOZ", "BALEARES", "BARCELONA", "BIZKAIA", "BURGOS", "CACERES", "CADIZ", "CANTABRIA", "CASTELLON", "CIUDAD REAL", "CORDOBA", "A CORUÑA", "CUENCA", "GIPUZKOA", "GIRONA", "GRANADA", "GUADALAJARA", "HUELVA", "HUESCA", "JAEN", "LEON", "LLEIDA", "LUGO", "MADRID", "MALAGA", "MURCIA", "NAVARRA", "OURENSE", "PALENCIA", "LAS PALMAS", "PONTEVEDRA", "LA RIOJA", "SALAMANCA", "TENERIFE", "SEGOVIA", "SEVILLA","SORIA", "TARRAGONA", "TERUEL", "TOLEDO", "VALENCIA", "VALLADOLID", "ZAMORA", "ZARAGOZA", "CEUTA" and "MELILLA"

Value

It is a xlsx which is host in the data_poblacion which, in turn, is located inside the working directory called pob_q_year_provincia.xls. If extr is TRUE, the file is called pob_e_year_provincia.xls. In case of anual is TRUE the file is called pob_a_year_provincia.xls. There is not data for foreign population by one or five-year age, the combination of extr=TRUE and anual=TRUE will generate an error message (“No data for these cases”).

See Also

Other download functions: getbase.fen, getbase.paro

Examples

1
getbase.pob(2005,"Madrid")

amvallone/DataSpa documentation built on Sept. 4, 2019, 12:03 p.m.