Package 'datana'

Title: Datasets and Functions to Accompany Analisis De Datos Con R
Description: Datasets and functions to accompany the book 'Analisis de datos con el programa estadistico R: una introduccion aplicada' by Salas-Eljatib (2021, ISBN: 9789566086109). The package helps carry out data management, exploratory analyses, and model fitting.
Authors: Christian Salas-Eljatib [aut, cre] , Pino Nicolas [ctb] (up to 2020), Riquelme Joaquin [ctb] (up to 2020)
Maintainer: Christian Salas-Eljatib <[email protected]>
License: GPL-3
Version: 1.0.5
Built: 2025-03-09 04:42:19 UTC
Source: https://github.com/cran/datana

Help Index


Datasets and Functions to Accompany Analisis De Datos Con R

Description

The datana package provides the datasets and functions that accompany the book "Análisis de datos con el programa estadístico R: una introducción aplicada" by Salas-Eljatib (2021, ISBN: 9789566086109). You can visit the book's website at https://eljatib.com/rlibro.

Notice that every dataframe has a counterpart but has column names in Spanish. For instance, the dataframe 'crown' has column names in English, but 'crown2' has column names in Spanish. Both data frames have the same data.

Details

The package contains several datasets for exploratory data analysis in an array of disciplines. Furthermore, datana provides functions as tools for descriptive statistics and plotting.

To see the preferable citation of the package, type citation("datana").

Author(s)

Christian Salas-Eljatib [aut, cre] (<https://orcid.org/0000-0002-8468-0829>), Pino Nicolas [ctb] (up to 2020), Riquelme Joaquin [ctb] (up to 2020)

Maintainer: Christian Salas-Eljatib <[email protected]>

Christian Salas-Eljatib is also indebted to several people who have contributed to individual data frames and functions: see credits in help pages.

References

Salas-Eljatib C. 2021. Análisis de datos con el programa estadístico R: una introducción aplicada. Santiago, Chile: Ediciones Universidad Mayor. ISBN: 9789566086109. https://www.buscalibre.cl/libro-analisis-de-datos-con-el-programa-estadistico-r/9789566086109/p/53775485

Examples

##scatter-plot and marginal histograms
data(treevolroble)
df <- treevolroble
xyhist(x=df$dbh,y=df$toth, xlab="Variable X",  ylab="Variable Y")

##scatter-plot and box-plots 
data(fishgrowth)
df <- fishgrowth
xyboxplot(x=df$length,y=df$scale)

About the R-Squared statistics: the Anscombe quartet dataset

Description

A dataset that contains four pairs of columns with the same descriptive statistics; however, there is a difference when representing the points through a graph.

Usage

data(aboutrsq)

Format

The data frame contains four variables as follows:

X1

Integers values that represent X-axis for Y1, Y2 and Y3 column

Y1

Float values that represent Y-axis for X1 column

Y2

Float values that represent Y-axis for X1 column

Y3

Float values that represent Y-axis for X1 column

X2

Integers values that represent X-axis for Y4 column

Y4

Float values that represent Y-axis for X2 column

Source

Data were assembled by Dr Christian Salas-Eljatib (Santiago, Chile).

References

Anscombe, Francis J. (1973). Graphs in statistical analysis. The American Statistician, 27, 17-21. doi:10.2307/2682899

Examples

data(aboutrsq)    
head(aboutrsq)

Sobre el estadístico R2: los datos del cuarteto de Anscombe

Description

Dataset que contiene cuatro pares de columnas con la mismos estadísticos descriptivos, sin embargo, si existe diferencia al representar los puntos mediante un gráfico.

Usage

data(aboutrsq2)

Format

Variables se describen a continuación::

X1

Valores enteros que representan el eje X para las columnas Y1, Y2 e Y3

Y1

Valores flotantes que representan el eje Y para la columna X1

Y2

Valores flotantes que representan el eje Y para la columna X1

Y3

Valores flotantes que representan el eje Y para la columna X1

X2

Valores enteros que representan el eje X para las columnas Y4

Y4

Valores flotantes que representan el eje Y para la columna X2

Source

Datos fueron contribuidos por el Prof. Christian Salas-Eljatib (Universidad de Chile, Santiago, Chile).

References

Anscombe FJ. 1973. Graphs in statistical analysis. The American Statistician, 27, 17-21. doi:10.2307/2682899

Examples

data(aboutrsq2)    
head(aboutrsq2)

Airquality data in New York city.

Description

Daily air quality measurements in New York, May to September 1973.

Usage

data(airnyc)

Format

Contains 6 variables, as follows:

ozone

numeric Ozone (ppb).

solar

numeric Solar R (lang).

wind

numeric Wind (mph).

temp

numeric Temperature (degrees F).

month

numeric Month (1–12).

day

numeric Day of month (1–31).

Source

The data were obtained from the library 'datasets'.

References

Chambers J, Cleveland W, Kleiner B, Tukey P. 1983. Graphical Methods for Data Analysis. Belmont. CA: Wadsworth.

Examples

data(airnyc)    
head(airnyc)

Calidad del aire en la ciudad de Nueva York.

Description

Calidad del aire diario medido en New York, de Mayo a Septiembre de 1973.

Usage

data(airnyc2)

Format

Contiene 6 variables:

ozone

Ozono (ppb).

solar

Solar R (largo).

wind

Viento (mph).

temp

Temperatura (grados F).

month

Mes del año (1–12).

day

Dia del mes (1–31).

Source

Los datos fueron obtenidos desde la librería 'datasets'.

References

Chambers J, Cleveland W, Kleiner B, Tukey P. 1983. Graphical Methods for Data Analysis. Belmont. CA: Wadsworth.

Examples

data(airnyc2)    
head(airnyc2)

Time series of annual precipitations in cities of Chile.

Description

Data contains annual precipitations in six cities in Chile (Santiago, Talca, Chillan, Temuco, Valdivia, and Puerto Montt) at different years.

Usage

data(annualppCities)

Format

The dataframe contains three variables as follows:

city

Name of city.

year

Year of registry.

annual

Value of the annual precipitation of a given year (mm).

Source

The data were obtained from https://explorador.cr2.cl/.

Examples

data(annualppCities)    
head(annualppCities)

Serie de tiempo de precipitaciones anuales en Chile.

Description

Data contains annual precipitations in six cities in Chile (Santiago, Talca, Chillan, Temuco, Valdivia, and Puerto Montt) at different years.

Usage

data(annualppCities2)

Format

The dataframe contains three variables as follows:

ciudad

Name of city.

anho

Year of registry.

pp.anual

Value of the annual precipitation of a given year (mm).

Source

Los datos fueron obtenidos desde https://explorador.cr2.cl/.

Examples

data(annualppCities2)    
head(annualppCities2)

Contains plot-level variables in Araucaria araucana forests in southern Chile.

Description

These are plot-level measurement data from the Araucaria araucana forests in southern Chile, measured in 2009. The data was based on fixed-area plots of 1000 m2^{2}. They are two forest stands.

Usage

data(araucaria)

Format

Contains plot-level variables as follows:

stand

Stand number

plot.no

Plot sample identificator number

x.utm

UTM coordinate in X-axis, in km

y.utm

UTM coordinate in Y-axis, in km

slope

Slope, in %

aspect

Aspect, in degrees

eleva

Elevation, in msnm

nha

Tree density, in trees/ha

gha

Basal area, in m2^{2}/ha

hdom

Dominant height, in m

vha

Gross stand volume, m3^{3}/ha

dg

Diameter of the average basal area tree of the plot, in cm

Source

The data are provided courtesy of Dr Nelson Ojeda at Universidad de La Frontera (Temuco, Chile).

References

Salas C, Ene L, Ojeda N, Soto H. 2010. Metodos estadísticos parametricos y no parametricos para predecir variables de rodal basados en Landsat ETM+: una comparacion en un bosque de Araucaria araucana en Chile [Parametric and non-parametric statistical methods for predicting plotwise variables based on Landsat ETM+: a comparison in an Araucaria araucana forest in Chile]. Bosque 31(3): 179-194.

Examples

data(araucaria)    
head(araucaria)

Variables a nivel de parcela para bosques de Araucaria araucana el sur de Chile.

Description

Estos son variables a nivel de parcela para bosques Araucaria araucana en el sur de Chile, medidos en 2009. Estas variables se basan en mediciones realizadas en parcelas de muestreo de superficie fija de 1000 m2^{2}. Hay dos rodales.

Usage

data(araucaria)

Format

Contains plot-level variables as follows:

rodal

Stand number

parcela

Plot sample identificator number

x.utm

UTM coordinate in X-axis, in km

y.utm

UTM coordinate in Y-axis, in km

pendiente

Slope, in %

exposicion

Aspect, in degrees

altitud

Elevation, in msnm

nha

Densidad, en arb/ha

gha

Area basal, en m2^{2}/ha

hdom

Altura dominante, en m

vha

Volumen bruto, en m3^{3}/ha

dg

Diameter medio cuadratico, en cm

Source

Los datos a nivel de árbol fueron cedidos por el Dr Nelson Ojeda de la Universidad de La Frontera (Temuco, Chile).

References

Salas C, Ene L, Ojeda N, Soto H. 2010. Metodos estadísticos parametricos y no parametricos para predecir variables de rodal basados en Landsat ETM+: una comparacion en un bosque de Araucaria araucana en Chile. Bosque 31(3): 179-194.

Examples

data(araucaria2)    
head(araucaria2)

Annual basal area increment for four tree species.

Description

The dataset contains 157 observations of the last ten years in 6-8 adult trees of different species at three elevations of altitudinal gradients sampled in four locations in Chile and two in Spain.

Usage

data(baiTreelines)

Format

Contains seven columns, as follows:

climate

Climate of each location, mediterranean and temperate.

site

Name of Location of study (termmas:Termas de Chillan , antillanca:Antillanca area within Puyehue National Park, castillo:Cerro Castillo Natural Reserve, farellones:Farellones in Central Chile, pyrenees: Sierra de Cutas area in Spanish Central Pyrenees,sierra:Sierra Nevada).

species

name species of study (lenga: Nothofagus pumilio, frangel: Kageneckia angustifolia, uncinata: Pinus uncinata, sylvestris: Pinus sylvestris).

elevation

Type of elevation. "Treeline", intermediate named as "inter", and closed or montane forest named as low.

tree

Id for tree.

bai

Value of annual basal area increment.

mean.bai

Mean of annual basal area increment.

Source

The data were obtained from the DRYAD repository at doi:10.5061/dryad.ks97h.

References

Piper F, Vinegla B, Linares J, Camarero J, Cavieres L, Fajardo A. 2016. Mediterranean and temperate treelines are controlled by different environmental drivers. Journal of of Ecology. 104: 691-702.

Examples

data(baiTreelines)    
head(baiTreelines)

Incremento anual en area basal de cuatro especies arboreas.

Description

Este set de datps contiene 157 observaciones, de los ultimos 10 años en 6-8 árboles adultos de cuatro especies en un gradiente altitudinal. Las muestras se distribuyeron en cuatro localidades o sitios de Chile y dos en España.

Usage

data(baiTreelines2)

Format

Contains seven columns, as follows:

clima

Climate of each location, mediterranean and temperate.

sitio

Name of Location of study (termmas:Termas de Chillan , antillanca:Antillanca area within Puyehue National Park, castillo:Cerro Castillo Natural Reserve, farellones:Farellones in Central Chile, pyrenees: Sierra de Cutas area in Spanish Central Pyrenees,sierra:Sierra Nevada).

especie

name species of study (lenga: Nothofagus pumilio, frangel: Kageneckia angustifolia, uncinata: Pinus uncinata, sylvestris: Pinus sylvestris).

tipo.altitud

Type of elevation. "Treeline", intermediate named as "inter", and closed or montane forest named as low.

arbol

Id for tree.

bai

Value of annual basal area increment.

bai.medio

Mean of annual basal area increment.

Source

The data were obtained from the DRYAD repository at doi:10.5061/dryad.ks97h.

References

Piper F, Vinegla B, Linares J, Camarero J, Cavieres L, Fajardo A. 2016. Mediterranean and temperate treelines are controlled by different environmental drivers. Journal of Ecology. 104: 691-702.

Examples

data(baiTreelines2)    
head(baiTreelines2)

Age and physical measurement data for wild bears

Description

Wild bears were anesthetized, and their bodies were measured and weighed. One goal of the study was to make a table (or perhaps a set of tables) for people interested in estimating the weight of a bear based on other measurements. Notice that there are missing values for some of the variables.

Usage

data(bears)

Format

Contains individual-level variables, as follows:

id

Bear id

age

Age in total number of months.

month

Month number within a given year.

sex

1 =male, 2 = female.

headL

Length of head, in cm.

headW

Width of head, in cm.

neckG

Girth of neck, in cm.

length

Body length, in cm.

chestG

Girth of chest, in cm.

weight

body weight, in kg.

obs

Temporal observation number for bear.

name

Name given to bear.

Source

According to Prof. Timothy Gregoire at Yale University (New Haven, CT, USA), the data set was supplied by Gary Alt.

References

Entertaining references are in Reader's Digest April, 1979, and Sports Afield September, 1981.

Examples

data(bears)    
head(bears) 
table(bears$sex)
boxplot(headL~sex, data=bears)

Edad y características biométricas de osos salvajes

Description

Los osos salvajes fueron anestesiados y sus cuerpos medidos. Uno de los objetivos del estudio fue hacer una tabla (o quizas un conjunto de tablas) para las personas interesadas en estimar el peso de un oso basandose en otras medidas. Observe que faltan valores para algunas de las variables.

Usage

data(bears2)

Format

Contiene variables de nivel individual, como se describen a continuacion:

id

Identificador del oso

edad

edad en meses

mes

Diámetro a la altura del pecho, en cm

sexo

1 = hombre, 2 = mujer

cabezaL

longitud de la cabeza, en cm

cabezaA

ancho de la cabeza, en cm

cuelloP

circunferencia del cuello, en cm

largo

longitud del cuerpo, en cm

pechoG

circunferencia del pecho, en cm

peso

peso corporal, en kg

obs

número de observación temporal para el oso

nombre

nombre dado al oso

Source

Segun el Prof. Timothy Gregoire de Yale University (New Haven, CT, USA), los datos fueron cedidos por Gary Alt. Minitab, Inc. La descripcion de los datos fue dada por él.

References

Algunas referencias generales estan en el Reader's Digest de Abril, 1979, y Sports Afield de Septiembre, 1981.

Examples

data(bears2)    
head(bears2) 
table(bears2$sexo)
boxplot(cabezaL~sexo, data=bears2)

Age and physical measurement data for wild bears (without missing values)

Description

Wild bears were anesthetized, and their bodies were measured and weighed. One goal of the study was to make a table (or perhaps a set of tables) for people interested in estimating the weight of a bear based on other measurements.

Usage

data(bearsDepu)

Format

Individual-level variables, as follows:

id

Bear identificator.

age

Age in total number of months.

month

Month number within a given year.

sex

Sex code: 1 =male, 2 = female.

headL

Length of head, in cm.

headW

Width of head, in cm.

neckG

Girth of neck, in cm.

length

Body length, in cm.

chestG

Girth of chest, in cm.

weight

Body weight, in kg.

obs

Temporal observation number for bear.

name

name given to bear

Source

According to Prof. Timothy Gregoire at Yale University (New Haven, CT, USA), the data set was supplied by Gary Alt.

References

Entertaining references are in Reader's Digest April, 1979, and Sports Afield September, 1981.

Examples

data(bearsDepu)    
head(bearsDepu)
table(bearsDepu$sex)
boxplot(headL~sex, data=bearsDepu)

Edad y características biométricas de osos salvajes (sin datos faltantes)

Description

Los osos salvajes fueron anestesiados y sus cuerpos medidos. Uno de los objetivos del estudio fue hacer una tabla (o quizas un conjunto de tablas) para las personas interesadas en estimar el peso de un oso basandose en otras medidas. Esta dataframe es igual que "bears" pero sin valores perdidos.

Usage

data(bearsDepu2)

Format

Contiene variables de nivel individual, como se describen a continuacion:

id

Identificador del oso.

edad

edad en meses.

mes

Diámetro a la altura del pecho, en cm.

sexo

1 = hombre, 2 = mujer.

cabezaL

longitud de la cabeza, en cm.

cabezaA

ancho de la cabeza, en cm.

cuelloP

circunferencia del cuello, en cm.

largo

longitud del cuerpo, en cm.

pechoG

circunferencia del pecho, en cm.

peso

peso corporal, en kg.

obs

número de observación temporal para el oso.

nombre

nombre dado al oso.

Source

Segun el Prof. Timothy Gregoire de Yale University (New Haven, CT, USA), los datos fueron cedidos por Gary Alt. Minitab, Inc. La descripcion de los datos fue dada por el .

References

Algunas referencias generales estan en el Reader's Digest de Abril, 1979, y Sports Afield de Septiembre, 1981.

Examples

data(bearsDepu2)    
head(bearsDepu2)
table(bearsDepu2$sexo)
boxplot(cabezaL~sexo, data=bearsDepu2)

Population density growth of beetles

Description

Temporal measurements of density of beetles (Tribolium confusum) growing in different controlled environments.

Usage

beetles

Format

days

Number of days.

diet

The quantities of flour (in grams) of the environments where the beetles were growing. Six levels of the factor Diet.

type

The various stage of beetles, i.e., eggs, larvae, pupae, and adults.

density

The number of insects per environment.

Source

Data from Table No. 1, page 116, of Chapman (1928). Series of experiments under controlled conditions in which flour beetles (Tribolium confusum) are kept in environments of known size. The period from egg to adult is approximately forty days at 27C degrees. The data were entered by Yamara Arancibia, a former student of Prof. Christian Salas-Eljatib.

References

- Chapman RN. 1928. The Quantitative Analysis of Environmental Factors. Ecology 9(2):111-122.

Examples

data(beetles)    
name.diet<-unique(beetles$diet)
num.diet<-length(name.diet)
##Time series plot
#first, some computation
alys<-with(beetles,tapply(density, list(as.factor(days),as.factor(diet)),sum))
out<-as.data.frame(alys)
out$time<-row.names(out)
head(out)
#Figure 1 of the paper
matplot(out[,"time"], out[,1:num.diet], las=1, type=c("b"),pch=1,
        xlab="Time in days",ylab="Total individuals")
legend("topleft", legend = name.diet, title = "Diet (gr)",
       col = 1:6, lty = 1:6, pch = 1)

Crecimiento poblacional de escarabajos

Description

Mediciones temporales de densidad de escarabajos (Tribolium confusum) creciendo en diferentes ambientes controlados.

Usage

beetles2

Format

dias

Número de dias.

dieta

La cantidad de harina (en gramos) de ambientes donde crecen los escarabajos. Seis niveles del factor Dieta.

tipo

Estados de desarrollo de los escarabajos, i.e., huevos, larvas, pupas, y adultos.

densidad

Número total de individuos por ambiente de crecimiento.

Source

Datos del Cuadro No. 1, page 116, de Chapman (1928). Serie de experimentos bajo condiciones controladas donde escarabajos (Tribolium confusum) se mantienen en ambientes de tamaño conocido. El periodo desde huevo a adulto es de aproximadamente de cuarenta dias a 27 grados Celsius. Los datos fueron digitados por Yamara Arancibia, una estudiante del Prof. Christian Salas-Eljatib.

References

- Chapman RN. 1928. The Quantitative Analysis of Environmental Factors. Ecology 9(2):111-122.

Examples

data(beetles2)    
nom.dieta<-unique(beetles2$dieta)
num.dieta<-length(nom.dieta)
##Grafico de serie de tiempo
#primero algunos calculos
alys<-with(beetles2,tapply(densidad, list(as.factor(dias),as.factor(dieta)),sum))
out<-as.data.frame(alys)
out$tiempo<-row.names(out)
head(out)
##Figura 1 del paper
matplot(out[,"tiempo"], out[,1:num.dieta], las=1, type=c("b"),pch=1,
        xlab="Tiempo en dias",ylab="Densidad de individuos")
legend("topleft", legend = nom.dieta, title = "Dieta (gr)",
       col = 1:6, lty = 1:6, pch = 1)

Contains tree-level biomass data for several species in Canada.

Description

These are tree-level variables for several species in Canada.

Usage

biomass

Format

treenum

tree number.

spp

species common name.

dbh

diameter at breast height, in cm.

height

total height, in m.

totbiom

total biomass, in kg.

bolebiom

stem biomass, in kg.

branchbiom

branches biomass, in kg.

foliagebiom

foliage biomass, in kg.

Source

The data are provided courtesy of Prof. Timothy Gregoire at the School of Forestry and Environmental Studies at Yale University (New Haven, CT, USA).

Examples

data(biomass)    
head(biomass)

Biomasa a nivel de árbol para especies arboreas de Canada.

Description

These are tree-level variables for several species in Canada.

Usage

biomass2

Format

treenum

tree number.

spp

species common name.

dbh

diameter at breast height, in cm.

height

total height, in m.

totbiom

total biomass, in kg.

bolebiom

stem biomass, in kg.

branchbiom

branches biomass, in kg.

foliagebiom

foliage biomass, in kg.

Source

The data are provided courtesy of Prof. Timothy Gregoire at the School of Forestry and Environmental Studies at Yale University (New Haven, CT, USA).

Examples

data(biomass2)    
head(biomass2)

Carbohydrates concentrations of tree species.

Description

Dataset contains 863 observations, about of total soluble carbohydrate, starch, and non structural carbohydrates concentrations per mass unit and per volume unit, in three tissues in early summer and early autumn 6-8 adult trees of different species at three elevations of altitudinal gradients sampled in four locations of Chile and Spain.

Usage

data(carbohydrateTreelines)

Format

Contains 16 variables, as follows:

climate

Climate of each location, mediterranean and temperate.

site

Name of Location of study (termas:Termas de Chillan , antillanca:Antillanca area within Puyehue National Park, castillo:Cerro Castillo Natural Reserve, farellones:Farellones in Central Chile, pyrenees: Sierra de Cutas area in Spanish Central Pyrenees,sierra:Sierra Nevada).

species

name species of study (lenga: Nothofagus pumilio, frangel: Kageneckia angustifolia, uncinata: Pinus uncinata, sylvestris: Pinus sylvestris).

tissue

Type of tissue, new developing twings, stem sapwood and branches.

time

Meauserement season (spring or autumn).

elevation

Type of elevation. "Treeline", intermediate named as "mid", and closed or montane forest named as "low".

tree

Id for tree.

tree.site

Id site for each location of study.

tss

Value of concentrations soluble carbohydrate per mass unit.

st

Value of concentrations starch per mass unit.

nsc

Value of concentrations non structural carbohydrates per mass unit.

tss.nsc

.

wd

It might be 'wood density', but not sure.

tss.mv

Value of concentrations soluble carbohydrate per volume unit.

st.mv

Value of concentrations starch per volume unit.

nsc.mv

Value of concentrations non structural carbohydrates per volume unit.

Source

The data were obtained from the DRYAD repository at doi:10.5061/dryad.ks97h.

References

Piper F, Vinegla B, Linares J, Camarero J, Cavieres L, Fajardo A. 2016. Mediterranean and temperate treelines are controlled by different environmental drivers. Journal of Ecology. 104: 691-702.

Examples

data(carbohydrateTreelines)    
head(carbohydrateTreelines)

Computes the cumulative distribution for a given random variable

Description

Cumulative distribution for a given random variable.

Usage

cdf(y = y)

Arguments

y

a vector of a random variable

Details

The cumulative distribution of the random variable is build every 5 the data at hand, that is to say, from 0.05 (i.e., 5

Value

The function returns a dataframe having two columns: the first contains the random variable values and the second the cumulative distribution for the variable.

Author(s)

Christian Salas-Eljatib

Examples

y.var <- rnorm(10)
cdf(y.var)

Chicken growth data.

Description

The body weights of the chicks were measured at birth and every second day thereafter until day 20. They were also measured on day 21. There were four groups on chicks on different protein diets.

Usage

data(chicksw)

Format

Contains four variables, as follows:

weight

A numeric vector giving the body weight of the chick (gm).

time

A numeric vector giving the number of days since birth when the measurement was made.

chick

An ordered factor with levels different giving a unique identifier for the chick. The ordering of the levels groups chicks on the same diet together and orders them according to their final weight (lightest to heaviest) within diet.

diet

A factor with levels 1,2,3 and 4 indicating which experimental diet the chick received.

Source

The data were obtained from the alr4 library.

References

Crowder M, Hand D. 1990. Analysis of Repeated Measures. Chapman and Hall

Examples

data(chicksw)    
head(chicksw)

Computes statistics for inference in a given contrast

Description

The function computes the statistics for inference in a given contrast, subject to a given significance level. Those statistics are as follows: estimated contrast, standard error of the contrast, and confidence interval of the contrast.

Usage

contrast(
  model = model,
  coef.cont = coef.cont,
  grp.m = grp.m,
  grp.n = grp.n,
  alpha = 0.05,
  full = TRUE
)

Arguments

model

object containing the fitted model

coef.cont

vector with the coefficients to establish the contrasts

grp.m

a vector having the sample mean per each group, or level of the factor under study.

grp.n

a vector having the sample size per each group, or level of the factor under study.

alpha

is the significance level for building the confidence intervals. Default value is 0.05, which is 95% confidence level.

full

FALSE if want short output, TRUE for longer (i.e. more details). Default is TRUE.

Details

The contrast is established based upon an already fitted statistical model that describe the relationship among variables. The significance level (alpha) is defined by the user, although by default has been set to 0.05, that is to say, a 95 statistical confidence.

Value

This function returns the above described statistics for a given contrast.

Author(s)

Christian Salas-Eljatib

References

Stage AR. 1963. A mathematical approach to polymorphic site index curves for Grand fir. Forest Science 9(2):167–180.

Examples

data(fertiliza)
table(fertiliza$treat)
means.trt <- tapply(fertiliza$volume,fertiliza$treat,mean);means.trt
sds.trt <- tapply(fertiliza$volume,fertiliza$treat,sd);sds.trt
ns.trt <- tapply(fertiliza$volume,fertiliza$treat,length);ns.trt
m1 <- lm(volume ~ treat, data=fertiliza)
anova(m1)
## Coefficients to be used in the contrast
#c1: (tmoA1-A2) - (tmoA3-A4)
C1.coeff <- c(0,1,1,-1,-1)
contrast(model=m1,C1.coeff,grp.m=means.trt,grp.n=ns.trt,alpha=0.1,full=TRUE)
contrast(model=m1,C1.coeff,grp.m=means.trt,grp.n=ns.trt,alpha=0.1,full=FALSE)
contrast(m1,C1.coeff,grp.m=means.trt,grp.n=ns.trt,alpha=0.05,full=TRUE)
contrast(m1,C1.coeff,grp.m=means.trt,grp.n=ns.trt)

Tree-level cork biomass data for Oak trees in Portugal

Description

Measurements of cork weight in sample trees of Quercus suber (Oak) in Portugal.

Usage

corkoak

Format

tree

A correlative number for each sample tree.

csc

is tree circumference at 1.3 m outside bark, in cm.

cbc

is tree circumference at 1.3 m under bark, in cm.

bt

bark thickness, in cm.

hdeb

is debarking height, in m.

hblc

height to base of live crown, in m.

nb

number of branches debarked

cr.diam

crown diameter, in m.

w

total green weight of the stripped cork, in kg

stratum

Stratum

Source

Data supplied electronically to Prof. Timothy Gregoire (Yale University) by authors accompanied by a note which said "After the article was published we discovered a problem with 2 of the observations so Teresa and I decided it was best just to delete them."

References

- Fonseca TJ, Parresol BR. 2001. A new model for cork weight estimation in northern Portugal with methodology for construction of confidence intervals. Forest Ecology and Management 152(1):131–139.

Examples

data(corkoak)    
head(corkoak)

Datos de biomasa de corcho en árboles de Encino en Portugal

Description

Mediciones de peso de corcho en árboles muestra de Quercus suber en Portugal.

Usage

corkoak2

Format

arbol

A correlative number for each sample tree.

perimetro.cc

is tree circumference at 1.3 m outside bark, in cm.

perimetro.sc

is tree circumference at 1.3 m under bark, in cm.

e.corteza

bark thickness, in cm.

h.desc

is debarking height, in m.

hcc

height to base of live crown, in m.

num.ram

number of branches debarked

diam.copa

crown diameter, in m.

biomasa

total green weight of the stripped cork, in kg

estrato

Estrato

Source

Datos cedidos por Prof. Timothy Gregoire (Yale University) y los autores originales mencionaron "After the article was published we discovered a problem with 2 of the observations so Teresa and I decided it was best just to delete them."

References

- Fonseca TJ, Parresol BR. 2001. A new model for cork weight estimation in northern Portugal with methodology for construction of confidence intervals. Forest Ecology and Management 152(1):131–139.

Examples

data(corkoak2)    
head(corkoak2)

Tree crown radii

Description

Crown radii measurements in cardinal directions for sample trees at the Rucamanque experimental forest, near Temuco, Chile. Data were collected within a sample plot of 250 m2^{2}, located in a secondary forest stand dominated by Nothofagus obliqua.

Usage

data(crown)

Format

Contains of variables, as follows:

spp

Species code. 'Ro' is Nothofagus obliqua (roble), 'Co' is Nothofagus dombeyi (Coigue) and 'Ol' is Olivillo.

dbh

Diameter at breast height, in cm.

toth

Total height, in m.

crad.n

Crown radii towards the north, in m.

crad.e

Crown radii towards the east, in m.

crad.s

Crown radii towards the south, in m.

crad.w

Crown radii towards the west, in m.

x.coord

Cardinal position at the X-axis, in m.

y.coord

Cardinal position at the Y-axis, in m.

cr.diam

Crown diameter, in m.

Source

Data were provided by Dr Christian Salas-Eljatib, Universidad de Chile (Santiago, Chile).

References

- Salas C. 2001. Caracterización básica del relicto de Biodiversidad Rucamanque [Basic characterization of the biodiversity remnant Rucamanque]. Bosque Nativo, 29:3-9. https://eljatib.com/publication/2001-06-01_caracterizacion_basi/

- Salas C, and Garcia O. 2006. Modelling height development of mature Nothofagus obliqua. Forest Ecology and Management 229 (1-3): 1-6. doi:10.1016/j.foreco.2006.04.015

Examples

data(crown)    
table(crown$spp) 
descstat(crown[,c("dbh","cr.diam")])

Radios de copa de árboles

Description

Mediciones de radios de copa en direcciones cardinales para árboles muestra en Rucamanque, cerca de Temuco, Chile. Los datos fueron colectados al interior de una parcela de muestreo de 250 m2^{2}, establecidad en un bosque secundario dominado por Nothofagus obliqua.

Usage

data(crown2)

Format

Contiene las siguientes columnas:

espe

Código de especie, donde: 'Ro' es Nothofagus obliqua (Roble), 'Co' es Nothofagus dombeyi (Coigue) y 'Ol' es Olivillo.

dap

Diámetro a la altura del pecho, en cm.

atot

Altura total, en m.

rc.n

Radio de copa hacia el Norte, en m.

rc.e

Radio de copa hacia el Este, en m.

rc.s

Radio de copa hacia el Sur, en m.

rc.w

Radio de copa hacia el Oeste, en m.

coord.x

Posición cartesiana en el eje-X, en m.

coord.y

Posición cartesiana en el eje-Y, en m.

dcopa

Diámetro de copa, en m.

Source

Datos cedidos por el Prof. Christian Salas-Eljatib, Universidad de Chile (Santiago, Chile).

References

- Salas C. 2001. Caracterización básica del relicto de Biodiversidad Rucamanque [Basic characterization of the biodiversity remnant Rucamanque]. Bosque Nativo, 29:3-9. https://eljatib.com/publication/2001-06-01_caracterizacion_basi/

- Salas C, and Garcia O. 2006. Modelling height development of mature Nothofagus obliqua. Forest Ecology and Management 229 (1-3): 1-6. doi:10.1016/j.foreco.2006.04.015

Examples

data(crown2)    
table(crown2$espe) 
descstat(crown2[,c("dap","dcopa")])

Data contains climatic, forest structure and forest mortality variable

Description

The data file contains one row per unique 3.5km grid cell by year combination. The data frame covers all grid cells within the state of California where at least one Aerial Detection Survey (ADS) flight was taken between 2009 and 2015, so each grid cell position has between 1 and 7 years of data (reflected as 1 to 7 rows in the data file per grid cell position). The main response variables are mort.bin (presence of any mortality) and mort.tph (number of dead trees/ha within the given grid cell by year).

Usage

data(deadForestCA)

Format

The data frame contains four variables as follows:

live.bah

Live basal area from the GNN dataset

live.tph

Live trees per hectare from the GNN dataset

pos.x

rank-order x-position of the grid cell (position 1 is western-most)

pos.y

rank-order y-position of the grid cell (position 1 is northern-most)

alb.x

x-coordinate of the grid cell centroid in California Albers (EPSG 3310)

alb.y

y-coordinate of the grid cell centroid in California Albers (EPSG 3310)

mort.bin

1= dead trees observed in grid cell. 0= no dead trees observed

mort.tph

Dead trees per hectare from the aggregated ADS dataset

mort.tpa

Dead trees per acre from the aggregated ADS dataset

year

Year of the ADS flight. Most flights occurred from May-August.

Defnorm

Mean annual climatic water deficit for the grid cell, for Oct 1-Sept 31 water year, averaged from 1981-2015

Def0

Climatic water deficit for the grid cell during the Oct-Sept water year overlapping the summer ADS flight of the given year

Defz0

Z-score for climatic water deficit for the given grid cell/water year. Calculated as (Def0-Defnorm)/(standard deviation in deficit among all years 1981-2015 for the given grid cell)

Defz1

Z-score for climatic water deficit for the given grid cell in the preceeding water year.

Defz2

Z-score for climatic water deficit for the given grid cell two water years prior.

Tz0

Z-score for temperature for the given grid cell/year.

Pz0

Z-score for precipitation for the given grid cell/year.

Defquant

FDCI variable. Quantile of Defnorm of the given grid cell, relative to the Defnorm of all other grid cells with a basal area within 2.5 m2^{2}/ha of the given cell is basal area.

Source

The data were provided from DRYAD repository.

References

-Derek J. N. Young, Jens T. Stevens, J. Mason Earles, Jeffrey Moore, Adam Ellis, Amy L. Jirka, and Andrew M. Latimer. Long-term climate and competition explain forest mortality patterns under extreme drought.Ecology Letters, 20(1):78-86, 2017.

-C. Salas-Eljatib, Andres Fuentes-Ramirez, Timothy G. Gregoire, Adison Altamirano, and Valeska Yaitul. A study on the effects of unbalanced data when fitting logistic regression models in ecology. Ecological Indicators, 85:502-508, 2018

Examples

data(deadForestCA)    
head(deadForestCA)

Los datos contienen variables climaticas, de estructura forestal y de mortalidad forestal.

Description

El archivo de datos contiene una fila por combinacion unica de celda de cuadricula de 3,5 km por año. El marco de datos cubre todas las celdas de la cuadricula dentro del estado de California donde se tomo al menos un vuelo de la Encuesta de deteccion aerea (ADS) entre 2009 y 2015, por lo que cada posicion de celda de la cuadricula tiene entre 1 y 7 años de datos (reflejados como 1 a 7 filas en el archivo de datos por posicion de celda de cuadricula). Las principales variables de respuesta son mort.bin (presencia de alguna mortalidad) y mort.tph (número de árboles muertos /ha dentro de la celda de la cuadricula por año).

Usage

data(deadForestCA2)

Format

Variables se describen a continuacion::

live.bah

Area basal viva del conjunto de datos GNN

live.tph

Árboles vivos por hectarea del conjunto de datos GNN

pos.x

posicion x del orden de clasificacion de la celda de la cuadricula (la posicion 1 es la mas occidental)

pos.y

posicion y del orden de clasificacion de la celda de la cuadricula (la posicion 1 es la mas al norte)

alb.x

coordenada x del centroide de la celda de la cuadricula en California Albers (EPSG 3310)

alb.y

coordenada y del centroide de la celda de la cuadricula en California Albers (EPSG 3310)

mort.bin

1 = árboles muertos observados en la celda de la cuadricula. 0 = no se observaron árboles muertos

mort.tph

Árboles muertos por hectarea del conjunto de datos ADS agregado

mort.tpa

Árboles muertos por acre del conjunto de datos ADS agregado

year

año del vuelo de ADS. La mayoría de los vuelos se realizaron entre mayo y agosto

Defnorm

Deficit hidrico climatico anual medio para la celda de la cuadricula, para el año hidrico del 1 de octubre al 31 de septiembre, promediado de 1981 a 2015

Def0

Deficit de agua climatica para la celda de la cuadricula durante el año hidrologico de octubre a septiembre que se superpone al vuelo ADS de verano del año dado

Defz0

Puntaje Z para el deficit hidrico climatico para la celda de cuadricula / año hidrico dado. Calculado como (Def0-Defnorm) / (desviacion estandar en el deficit entre todos los años 1981-2015 para la celda de la cuadricula dada

Defz1

Puntuacion Z para el deficit h?drico climatico para la celda de la cuadricula dada en el año hidrologico anterior.

Defz2

Puntuacion Z para el deficit hidrico climatico para la celda de la cuadricula dada dos años antes.

Tz0

Puntaje Z para la temperatura para la celda de cuadricula / año dado.

Pz0

Puntaje Z para la precipitacion para la celda / año de la cuadricula dado.

Defquant

Variable FDCI. Cuantil de Defnorm de la celda de la cuadricula dada, en relacion con la Defnorm de todas las demas celdas de la cuadricula con un area basal dentro de 2.5 m2^{2}/ha de la celda dada

Source

The data were provided from DRYAD repository.

References

-Derek J. N. Young, Jens T. Stevens, J. Mason Earles, Jeffrey Moore, Adam Ellis, Amy L. Jirka, and Andrew M. Latimer. Long-term climate and competition explain forest mortality patterns under extreme drought.Ecology Letters, 20(1):78-86, 2017.

-Salas-Eljatib C, Fuentes-Ramirez A., Gregoire TG, Altamirano A., and Yaitul V. A study on the effects of unbalanced data when fitting logistic regression models in ecology. Ecological Indicators, 85:502-508, 2018.

Examples

data(deadForestCA2)    
head(deadForestCA2)

This dataset has 43 columns and 4247 rows. Each row corresponds to an epiphyte individual located on the reliable sections of the host trees

Description

This study is part of the project "Diversity and dynamics of vascular epiphytes in Colombian Andes" supported by COLCIENCIAS (contract 2115-2013). The data corresponds to the first large-scale assessment of vascular epiphyte mortality in the neotropics. Based on two consecutive annual surveys, we followed the fate of 4247 epiphytes to estimate the epiphyte mortality rate on 116 host trees at nine sites. Additional variables were taken from the area of study in order to find relationships with epiphyte mortality.

Usage

data(deadLianas)

Format

The data frame contains four variables as follows:

PlotSite

Municipality name of the 9 study sites

Y.Plot

Latitude of the plot in decimal degrees

X.Plot

Longitude of the plot in decimal degrees

PhoroNo

ID number of the sampled host trees in each site

EpiFam

Epiphyte taxonomic family

EpiGen

Epiphyte taxonomic genus

cf.aff

Abbreviations of Latin terms in the context of taxonomy. cf. "confer" meaning "compare with". aff.: "affinis" meaning "similar to".

Species

Epiphyte (morpho) species name

Author

Author of the scientific name

EpiAzi

Azimuth of the epiphyte individual on each host tree

BraAzi

Azimuth of the branch in which the epiphyte individual was found

EpiDisTru

Distance in meters from the trunk to the epiphyte attachment site on a branch

EpiSize

Estimated size of the epiphyte individual in centimetres

EpiAttHei

Epiphyte attachment height in meters

Date0

Date of the first census

Date1

Date of the final census

Location

Section (roots, trunks, branches) of the host tree in which theepiphyte individual was found

Mortality

Dichotomous variable. 0 if the epiphyte individual was dead in the final census and 1 if otherwise

MorCat

Mechanical or non-mechanical cause of mortality

Elevation

Elevation (m a.s.l.) of the plot

AP_bio12

Annual precipitation in the plot (mm yr-1)

PDM_bio14

Precipitation of driest month in the plot (mm)

PS_bio15

Precipitation seasonality in the plot (coefficient of variation)

MDT_bio2

Mean Diurnal Range (Mean of monthly (max temp - min temp)) in the plot (oC*10)

TS_bio4

Temperature seasonality in the plot (standard deviation*100)

ATR_bio7

Annual temperature range in the plot (10 celsius degrees)

AET

Actual evapotranspiration in the plot (mm yr-1)

BasAre

Basal area of trees with DBH major or equal to 5 cm (AB) in the plot (m2^{2}/ha)

BasAre5_10

Basal area of trees with greater or equal than 5 DBH and less than 10 cm in the plot (m2^{2}/ha)

BasAre10

Basal area of trees with greater or equal than 10 cm DBH in the plot (m2^{2}/ha)

Ind10

Number of canopy trees (with greater or equal than 10 cm DBH ) in the plot

Ind5

Number of understory trees (with greater or equal than 5 DBH and less than 10 cm) in the plot

Ind5_10

Number of trees with greater or equal than 5 DBH and less than 10 cm in the plot

Ind10_15

Number of trees with greater or equal than 10 DBH and less than 15 cm in the plot

Ind15_20

Number of trees with greater or equal than 15 DBH and less than 20 cm in the plot

Ind20_25

Number of trees with greater or equal than 20 DBH and less than 25 cm in the plot

Ind25_30

Number of trees with greater or equal than 25 DBH and less than 30 cm in the plot

Ind30

Number of trees with DBH major or equal to 30 cm in the plot

TreeHei

Total tree height in meters

MedHei

Median height of trees in each plot

MaxHei

Maximum height of trees in each plot

BranchNumb

Number of branches of the host tree

Obs

Observations and notes in Spanish

Source

Data were extracted from Zuleta, D., Benavides, A.M., Lopez-Ros, V. & Duque, A. 2016. Local and regional determinants of vascular epiphyte mortality in the Andean mountains of Colombia .

References

Zuleta, D., Benavides, A.M., Lopez-Rios, V. & Duque, A. 2016. Local and regional determinants of vascular epiphyte mortality in the Andean mountains of Colombia.

Examples

data(deadLianas)    
head(deadLianas)

Este conjunto de datos tiene 43 columnas y 4247 filas. Cada fila corresponde a un individuo epifito ubicado en el secciones confiables de los árboles hospedantes

Description

Este estudio es parte del proyecto "Diversidad y din?mica de ep?fitas vasculares en los Andes colombianos". apoyado por COLCIENCIAS (contrato 2115-2013). Los datos corresponden a la primera gran escala evaluaci?n de la mortalidad de ep?fitas vasculares en los neotr?picos. Basado en dos encuestas anuales consecutivas, Seguimos el destino de 4247 ep?fitas para estimar la tasa de mortalidad de ep?fitas en 116 ?rboles hospedantes. en nueve sitios. Se tomaron variables adicionales del area de estudio para encontrar relaciones con mortalidad de epifitas.

Usage

data(deadLianas2)

Format

Variables se describen a continuacion::

PlotSite

Nombre del municipio de los 9 sitios de estudio

Y.Plot

Latitud del grafico en grados decimales

X.Plot

Longitud de la grafica en grados decimales

PhoroNo

número de identificacion de los árboles hospedantes muestreados en cada sitio

EpiFam

Familia taxonomica de epifitas

EpiGen

Genero taxonomico de epifitas

cf.aff

Abreviaturas de terminos latinos en el contexto de la taxonomia. cf. "conferir" que significa "comparar con". aff .: "affinis" que significa "similar a"

Species

Nombre de la especie epifita (morfo)

Author

Autor del nombre cientifico

EpiAzi

Azimut del individuo epifito en cada árbol huesped

BraAzi

Azimut de la rama en la que se encontro el individuo epifito

EpiDisTru

Distancia en metros desde el tronco hasta el sitio de union de la epifita en una rama

EpiSize

Tamaño estimado del individuo epifito en centimetros

EpiAttHei

Altura del accesorio de la epifita en metros

Date0

Fecha del primer censo

Date1

Fecha del censo final

Location

Seccion (raices, troncos, ramas) del árbol anfitrion en el que se encontro el individuo epifito

Mortality

Variable dicotomica. 0 si el individuo epifito estaba muerto en el censo final y 1 si no

MorCat

Causa de mortalidad mecanica o no mecanica

Elevation

Elevacion (msnm) de la parcela

AP_bio12

Precipitacion anual en la parcela (mm año-1)

PDM_bio14

Precipitacion del mes mas seco en la parcela (mm)

PS_bio15

Estacionalidad de la precipitacion en la parcela (coeficiente de variacion)

MDT_bio2

Rango diurno medio (Media mensual (temperatura maxima - temperatura minima)) en la grafica (10 grados celsius)

TS_bio4

Estacionalidad de la temperatura en la grafica (desviacion estandar * 100)

ATR_bio7

Rango de temperatura anual en la parcela (10 grados centigrados)

AET

Evapotranspiracion real en la parcela (mm año-1)

BasAre

Area basal de árboles con DAP mayor o igual a 5 cm (AB) en la parcela (m2^{2}/ha)

BasAre5_10

Area basal de árboles con DAP mayor o igual a 5 y menor a 10 cm en la parcela (m2^{2}/ha)

BasAre10

Area basal de árboles con DAP mayor o igual a 10 cm en la parcela (m2^{2}/ha)

Ind10

Número de árboles del dosel (con un DAP superior o igual a 10 cm) en la parcela

Ind5

Número de árboles de sotobosque (con DAP mayor o igual a 5 y menor a 10 cm) en la parcela

Ind5_10

Número de árboles con un DAP mayor o igual a 5 y menos de 10 cm en la parcela

Ind10_15

Número de árboles con un DAP mayor o igual a 10 y menos de 15 cm en la parcela

Ind15_20

Número de árboles con un DAP mayor o igual a 15 y menos de 20 cm en la parcela

Ind20_25

Número de árboles con un DAP mayor o igual a 20 y menos de 25 cm en la parcela

Ind25_30

Número de árboles con un DAP mayor o igual a 25 y menos de 30 cm en la parcela

Ind30

Número de árboles con DAP mayor o igual a 30 cm en la parcela

TreeHei

Altura total del árbol en metros

MedHei

Altura media de los árboles en cada parcela

MaxHei

Altura maxima de los árboles en cada parcela

BranchNumb

Número de ramas del árbol anfitrion

Obs

Observaciones y notas en español

Source

Data fue extraida desde Zuleta, D., Benavides, A.M., Lopez-Ros, V. & Duque, A. 2016. Local and regional determinants of vascular epiphyte mortality in the Andean mountains of Colombia .

References

Zuleta, D., Benavides, A.M., Lopez-Rios, V. & Duque, A. 2016. Local and regional determinants of vascular epiphyte mortality in the Andean mountains of Colombia.

Examples

data(deadLianas2)    
head(deadLianas2)

Deletes the last n-characters of a string

Description

Function to delete the last n-characters of a string from the right-hand side.

Usage

deleteRight(fac, n)

Arguments

fac

is an object of class string or factor

n

is the number of characters to be deleted of a the string given in 'fac'.

Details

It is specially set to arrange data vector having alphanumeric format.

Value

This function returns an object having n-less characters from the right-hand side.

Author(s)

Christian Salas-Eljatib

Examples

last.names.id <- c("Stage-1924","Gregoire-1958","Robinson-1967")
deleteRight(last.names.id,5)
deleteRight(last.names.id,4)

Contains information of demography of species.

Description

Dataset contains 61 observations about life histories values for each species and site, as obtained from the parameterization carried out in studies that used the model SORTIE

Usage

data(demograph)

Format

Contains 15 variables, as follows:

sp

Name specie.

site

Name of site of study.

country

Name of country.

site.n

Code of site.

code

Code of specie.

genus

Genus of specie.

sps

Abbreviated name specie.

family

Family of specie.

phyl

Type of phylogeny.

l.hab

Type of leaf habit.

l.type

.

leaf

Type of leaf.

growth.l

Growth at full light (time in years).

growth.d

Growth in shade.

surv.d

Survival in shade.

Source

The data were obtained from the DRYAD repository.

References

- Ameztegui A, Paquette A, Shipley B, Heym M, Messier C, Gravel D. 2016 . Shade tolerance and the functional trait: demography relationship in temperate and boreal forests. Functional Ecology 31: 821-830.

Examples

data(demograph)    
head(demograph)

Creates a descriptive statistics table for continuous variables

Description

Function to create a descriptive statistics table for continuous variables from a dataframe.

Usage

descstat(data = data, decnum = 4, full = FALSE)

Arguments

data

a dataframe containing numeric variables as columns.

decnum

the number of decimals to be used in the output.

full

TRUE for a longer output (i.e. more descriptive statistics). The default is to FALSE.

Details

The resulting table offers the main central and dispersion statistics.

Value

This function wraps descriptive statistics into a summarize table having the following descriptive statistics: sample size, minimum, maximum, mean, median, SD, and coefficient of variation. If the full option is set to TRUE, the following statistics are added to the table: 25th and 75th percentiles, the interquartile range, skewness, and kurtosis.

Author(s)

Christian Salas-Eljatib and Tomas Cayul.

Examples

#creating a ficticiuos dataframe
set.seed(1234)
df <- as.data.frame(cbind(variable1=rnorm(5, 0), variable2=rnorm(5, 2)))
## adding one missing value
df[3,1] <- NA
df
#' #using the function
descstat(data=df)
descstat(data=df,decnum=1)
descstat(df,2)

Presidential election data of Florida (USA) in 2000.

Description

County-by-county vote for president in Florida in 2000 for Bush, Gore and Buchanan.

Usage

data(election)

Format

Contains three variables, as follows:

gore

Vote for Gore.

bush

Vote for Bush.

buchanan

Vote for Pat Buchanan.

Source

The data were obtained from the 'alr4' library.

References

Weisberg S. 2014. Applied Linear Regression. 4th edition. Hoboken NJ: Wiley

Examples

data(election)    
head(election)

Elección presidencial en el estado de Florida (USA) en el 2000.

Description

Conteo de votos a nivel de condado en el estado de Florida, año 2000.

Usage

data(election2)

Format

Contiene las siguientes tres columnas:

gore

Votos para Gore. Número de votos para Al Gore.

bush

Votos para Bush. Número de votos para George W. Bush.

buchanan

Votos para Buchaman. Número de votos para Pat Buchanan.

Source

Los datos se obtuvieron desde el paquete 'alr4' de R.

References

Weisberg S. 2014. Applied Linear Regression. 4th edition. Hoboken NJ: Wiley

Examples

data(election2)    
head(election2)

Leaf measurements for Eucalyptus nitens trees in Tasmania, Australia.

Description

The length, width, and area of Eucalyptus nitens leaves were measured.

Usage

data(eucaleaf)

Format

Contains leaf-level variables, as follows:

time

Early or Late

tree

an identificator for a given sample tree

shoot

shoot description

l

length of the leaf, in mm

w

width of the leaf, in mm

la

leaf area, in cm2^{2}

Source

Although the original source of the measurements is the Dissertation of Dr Candy (1999), the data file used here was courtesy of Prof. Timothy Gregoire at Yale University (New Haven, CT, USA). Furthermore, these data were used by Gregoire and Salas (2009).

References

- Candy SG. 1999. Predictive models for integrated pest management of the leaf beetle Chrysophtharta bimaculata in Eucalyptus nitens in Tasmania. Doctoral dissertation, University of Tasmania, Hobart, Australia.

- Gregoire TG, and Salas C. 2009. Ratio estimation with measurement error in the auxiliary variate. Biometrics 65(2):590-598 doi:10.1111/j.1541-0420.2008.01110.x

Examples

data(eucaleaf)    
head(eucaleaf)

Mediciones foliares para árboles de Eucalyptus nitens en Tasmania, Australia.

Description

Mediciones de largo, ancho y area de hojas de Eucalyptus nitens.

Usage

data(eucaleaf)

Format

Contiene variables a nivel de hoja, como sigue:

tiempo

factor a dos niveles: Temprano o Tardio

arbol

un identificador del árbol muestra

meristema

descripcion del meristema

largo

largo de la hoja, en mm

ancho

ancho de la hoja, en mm

area

area foliar, en cm2^{2}

Source

Aunque la fuente original de estas mediciones proviene de la tesis del Dr Candy (1999), el archivo de datos fue cortesia del Prof. Timothy Gregoire de Yale University (New Haven, CT, USA). Ademas, estos datos fueron ocupados en el estudio de Gregoire y Salas (2009).

References

- Candy SG. 1999. Predictive models for integrated pest management of the leaf beetle Chrysophtharta bimaculata in Eucalyptus nitens in Tasmania. Doctoral dissertation, University of Tasmania, Hobart, Australia.

- Gregoire TG, and Salas C. 2009. Ratio estimation with measurement error in the auxiliary variate. Biometrics 65(2):590-598 doi:10.1111/j.1541-0420.2008.01110.x

Examples

data(eucaleaf2)    
head(eucaleaf2)

Leaf measurements (all, n=744) for Eucalyptus nitens trees in Tasmania, Australia.

Description

The length, width, and area of Eucalyptus nitens leaves were measured for all the samples of Candy (1999).

Usage

data(eucaleafAll)

Format

Contains leaf-level variables, as follows:

time

Early or Late

tree

an identificator for a given sample tree

shoot

shoot description

l

length of the leaf, in mm

w

width of the leaf, in mm

la

leaf area, in cm2^{2}

Source

Although the original source of the measurements is the Dissertation of Dr Candy (1999), the data file used here was courtesy of Prof. Timothy Gregoire at Yale University (New Haven, CT, USA). Furthermore, these data were used by Gregoire and Salas (2009).

References

- Candy SG. 1999. Predictive models for integrated pest management of the leaf beetle Chrysophtharta bimaculata in Eucalyptus nitens in Tasmania. Doctoral dissertation, University of Tasmania, Hobart, Australia.

Examples

data(eucaleafAll)    
head(eucaleafAll)

Mediciones foliares (todas, n=744) para árboles de Eucalyptus nitens en Tasmania, Australia.

Description

Mediciones de largo, ancho y area de hojas de Eucalyptus nitens para toda la muestra de Candy (1999).

Usage

data(eucaleafAll2)

Format

Contiene variables a nivel de hoja, como sigue:

tiempo

factor a dos niveles: Temprano o Tardio

arbol

un identificador del árbol muestra

meristema

descripcion del meristema

largo

largo de la hoja, en mm

ancho

ancho de la hoja, en mm

area

area foliar, en cm2^{2}

Source

Aunque la fuente original de estas mediciones proviene de la tesis del Dr. Candy (1999), el archivo de datos fue cortesia del Prof. Timothy Gregoire de Yale University (New Haven, CT, USA).

References

- Candy SG. 1999. Predictive models for integrated pest management of the leaf beetle Chrysophtharta bimaculata in Eucalyptus nitens in Tasmania. Doctoral dissertation, University of Tasmania, Hobart, Australia.

Examples

data(eucaleafAll2)    
head(eucaleafAll2)

Data from a Eucalyptus globulus plantation near Gorbea, Region de La Araucania, Chile.

Description

Tree-level data collected within a sample plot in a forestry plantation of Eucalyptus globulus near Gorbea, Southern Chile. The plot size is 500 m2^{2}. The plantation is 15 yr-old and had been subject to three thinnings.

Usage

data(eucaplot)

Format

The dataframe contains four variables as follows:

dbh

Diameter at breast height, in cm.

health

health status (1: good, 2: medium, 3: bad).

shape

stem shape for timber purposes (1: good, 2: medium, 3: bad).

crown.class

Crown class (1: superior, 2: intermedium, 3: lower).

toth

Total height, in m.

Source

The data were provided courtesy of Dr Christian Salas (Universidad de Chile, Santiago, Chile).

Examples

data(eucaplot)    
head(eucaplot)

Árboles dentro de parcelas de muestreo en una plantación de Eucalyptus globulus, Chile.

Description

Datos a nivel de árbol colectados dentro de una parcela de muestreo en una plantación forestal de Eucalyptus globulus cerca de Gorbea, Sur de Chile. La superficie de la parcela es de 500 m2^{2}. La plantación tiene 15 años de edad y ha estado sujeta a tres raleos.

Usage

data(eucaplot2)

Format

Los datos contienen las siguientes cuatro columnas:

dap

Diámetro a la altura del pecho, en cm.

sanidad

Evaluación cualitativa de la sanidad del árbol (1: buena, 2: media, 3: mala).

forma

Evaluación cualtitativa de la forma del fuste (1: buena, 2: media, 3: mala).

clase.copa

Clase de copa (1: superior, 2: intermedio, 3: inferior).

atot

Altura total, en m.

Source

Los datos fueron cedidos por el Prof. Christian Salas (Universidad de Chile, Santiago, Chile).

Examples

data(eucaplot2)    
head(eucaplot2)

Fertilization experiment data.

Description

Data contains volume data at plot-level for a fertilization experiment.

Usage

data(fertiliza)

Format

Contains three variables, as follows:

treat

Treatment level.

volume

Plot-level volume, in m3^{3}.

Source

The data were provided by Dr Christian Salas-Eljatib (Universidad de Chile, Santiago, Chile).

References

not yet

Examples

data(fertiliza)    
head(fertiliza) 
levels(fertiliza$treat)
means.g <- tapply(fertiliza$volume,fertiliza$treat,mean);means.g
sds.g <- tapply(fertiliza$volume,fertiliza$treat,sd);sds.g
ns.g <- tapply(fertiliza$volume,fertiliza$treat,length);ns.g

Datos a nivel de parcela de un experimento de fertilización

Description

Datos a nivel de parcela de un experimento de fertilización con tratamientos y replicas.

Usage

data(fertiliza2)

Format

Contiene tres columnas como sigue:

tmo

Tratamiento.Factor medido en diferentes niveles.

vol

Volumen de madera en la parcela experimental, en m3^{3}.

Source

Datos cedidos por el Prof. Christian Salas.

References

not yet

Examples

data(fertiliza2)    
head(fertiliza2) 
levels(fertiliza$tmo)
media.g <- tapply(fertiliza2$vol,fertiliza2$tmo,mean);media.g
desvst.g <- tapply(fertiliza2$vol,fertiliza2$tmo,sd);desvst.g
n.g <- tapply(fertiliza2$vol,fertiliza2$tmo,length);n.g

Diameter growth of trees

Description

The 'ficdiamgr' is a fictitious dataframe built to show the structure of longitudinal data. The dataframe has records of tree diameter growth of five sample trees, spanning three species.

Usage

data(ficdiamgr)

Format

A time series data containing the following columns:

tree.id

an ordered factor indicating the tree on which the measurement is made. The ordering is according to increasing maximum diameter.

time

a numeric vector giving the numbers of days since establishment.

dbh

a numeric vector of diameter at breast height, in cm.

site

a factor variable, representing site conditions with two levels.

spp

a factor variable, representing tree species with three levels.

Source

This dataframe was built from the 'Orange' data of the 'datasets' package, by Christian Salas-Eljatib.

Examples

data(ficdiamgr)

coplot(dbh ~ time | tree, data = ficdiamgr, show.given = FALSE)

Crecimiento diametral de árboles

Description

Los datos 'ficdiamgr2' son ficticios, y fue construida para mostrar la estructura de datos longitudinales. Los datos tienen registro de crecimiento en cinco árboles muestra, representando a tres especies.

Usage

data(ficdiamgr2)

Format

Una serie de tiempo conteniendo las siguientes columnas:

arbol

indica el identificador del árbol.

tiempo

número de dias desde el inicio de las mediciones.

dap

diámetro a la altura del pecho, en cm.

sitio

un factor, representando condiciones de sitio, en dos niveles.

espe

un factor, representando especie del árbol, en tres niveles.

Source

Estos datos fueron modificados desde la dataframe 'Orange' de la librería 'datasets', por Christian Salas-Eljatib.

Examples

data(ficdiamgr2)

coplot(dap ~ tiempo | arbol, data = ficdiamgr2, show.given = FALSE)

Finds the position of a specific variable.

Description

Sometimes in data manipulation we face the task of locating the position of a specific variable within a dataframe. The function finds the position in which a column name is within an object.

Usage

findColumn.byname(data = data, col.name = col.name)

Arguments

data

is a dataframe

col.name

is a string specifying the name of the variable

Details

Although the function finds the position of a specific variable, can also be used for more than one variable.

Value

This function returns the number of a specific column-name.

Note

It can be used for a vector of specified column-names as well.

Author(s)

Christian Salas-Eljatib

Examples

df <- data.frame(varX=1:5, varY=letters[1:5], varZ=rep("a",5), varK=rep("b",5))
df
#using the function
findColumn.byname(df, c("varY","varZ"))
findColumn.byname(df, "varK")
#Creating an example vector
vector <- letters
vector
findColumn.byname(vector, c("h","z"))

Data on fish growth.

Description

Data on samples of small mouth bass collected in West Bearskin Lake, Minnesota, in 1991. The file wblake includes only fish of ages 8 or younger.

Usage

data(fishgrowth)

Format

Contains 3 variables, as follows:

years

Year at capture.

length

Length at capture (mm).

scale

radius of a key scale (mm).

Source

The data were obtained from the alr4 library of R.

References

Weisberg S. 2014. Applied Linear Regression. 4th edition. Hoboken NJ: Wiley

Examples

data(fishgrowth)    
head(fishgrowth)

Crecimiento de peces

Description

Data on samples of small mouth bass collected in West Bearskin Lake, Minnesota, in 1991. The file wblake includes only fish of ages 8 or younger.

Usage

data(fishgrowth2)

Format

Contiene tres variables, como sigue:

edad

Year at capture.

largo

Length at capture, en mm.

escala

radius of a key scale, en mm.

Source

Datos obtenidos desde el paquete alr4 de R.

References

Weisberg S. 2014. Applied Linear Regression. 4th edition. Hoboken NJ: Wiley

Examples

data(fishgrowth2)    
head(fishgrowth2)

Flora of Chile.

Description

Dataset contains taxonomic level information segregatted by latitude.

Usage

data(floraChile)

Format

Contains seven columns, as follows:

family

.

genus

.

scientific.name

.

author

.

origin

.

life.form

.

lat...

.

Source

The data are provided courtesy of Dr Jan Bannister at the Instituto Forestal (Chiloe, Chile).

References

- Bannister JR, Vidal OJ, Teneb E, Sandoval V. 2012. Latitudinal patterns and regionalization of plant diversity along a 4270‐km gradient in continental Chile. Austral Ecology 37(4):500-509.

Examples

data(floraChile)    
head(floraChile)

Flora de Chile.

Description

Contiene informacion taxonomica segregada por latitude.

Usage

data(floraChile)

Format

Contains seven columns, as follows:

family

.

genus

.

scientific.name

.

author

.

origin

.

life.form

.

lat...

.

Source

Datos cedidos por el Dr Jan Bannister del Instituto Forestal (Chiloe, Chile).

References

- Bannister JR, Vidal OJ, Teneb E, Sandoval V. 2012. Latitudinal patterns and regionalization of plant diversity along a 4270‐km gradient in continental Chile. Austral Ecology 37(4):500-509.

Examples

data(floraChile2)    
head(floraChile2)

Anaerobic potential of soccer players.

Description

Data about anaerobic variables of football players.

Usage

data(football)

Format

The data frame contains 13 variables as follows:

WPM
WPMk
WPm
WPmk
WTT
WTTk
WIF
W5
W10
W15
W20
W25
W30

Source

Data were provided by Dr Aquiles Yanez-Silva at Universidad Mayor (Santiago, Chile).

References

Not yet.

Examples

data(football)    
head(football)

Potencia anaerobica de jugadores de football.

Description

Datos sobre potencia anaerobica de jugadores de football.

Usage

data(football2)

Format

Contiene variables de nivel individual, como se describen a continuacion::

WPM
WPMk
WPm
WPmk
WTT
WTTk
WIF
W5
W10
W15
W20
W25
W30

Source

Los datos fueron cedidos por el Dr Aquiles Yanez-Silva de la Universidad Mayor (Santiago, Chile).

References

Not yet.

Examples

data(football2)    
head(football2)

Data of forest fire occurrence

Description

Data of forest fire occurrence from Altamirano et al. (2013) as our population, containing 7210 total observations (N), with only 890 cases of fire occurrence (N 1 ) and 6320 cases of non occurrence (N 0 ). The binary variable (Y) is the occurrence of forest fire, where Y equal to 1 denotes occurrence and Y equal to 0 otherwise.

Usage

data(forestFire)

Format

The data frame contains four variables as follows:

fire

Presence of forest fire (1 yes, 0 no)

xcoord

Geographic coordinate x.utm

ycoord

Geographic coordinate y.utm

aspect

Exposure (degrees from north)

eleva

Elevation (m)

slope

Slope (degrees)

distr

Distance to dirt roads

distcity

Distance to cities

distriver

Distance to paved roads

covera

Land use classifications according to a polygon

coverb

Land use classifications according to a polygon

tempe

Minimum temperature of the coldest month

ppan

Annual precipitation

ndii

Normalized difference infrared index

nvdi

Normalized difference vegetation index

tempe2

Minimum temperature of the warmest month

ppan2

Precipitation of the driest month

frec.fire

Frequency of fires

perc.fire

Percentage of fire frequency

fireClass

Class for frecuency fire

asp.class

Class of variable exposure

eleva.class

Class of numerical variable elevation

slope.class

Class of numerical variable slope

ndii.class

Normalized difference infrared index class

nvdi.class

Normalized difference vegetation index class

Source

Data were provided by Dr Adison Altamirano at the Universidad de La Frontera (Temuco, Chile).

References

Altamirano A, Salas C, Yaitul V, Smith-Ramirez C, Avila A. Infuencia de la heterogeneidad del paisaje en la ocurrencia de incendios forestales en Chile Central. Revista de Geografia del Norte Grande, 55:157-170, 2013.

Examples

data(forestFire)    
head(forestFire)

Datos de ocurrencia de incendios forestales

Description

Datos de ocurrencia de incendios forestales de Altamirano et al. (2013) como nuestra poblacion, que contiene 7210 observaciones totales (N), con solo 890 casos de ocurrencia de incendios (N1) y 6320 casos de no ocurrencia (N0). La variable binaria (Y) es la ocurrencia de un incendio forestal, donde Y igual a 1 denota ocurrencia e igual a 0 en caso contrario.

Usage

data(forestFire2)

Format

Variables se describen a continuacion:

fire

Presencia de incendio forestal (1 si, 0 no)

xcoord

Coordenada geografica x.utm

ycoord

Coordenada geografica y.utm

aspect

Exposicion (grados desde el norte)

eleva

Elevacion (m)

slope

Pendiente (grados)

distr

Distancia a caminos de tierra

distcity

Distancia a ciudades

distriver

Distancia a caminos pavimentados

covera

Clasificaciones de uso del suelo segun un poligono

coverb

Clasificaciones de uso del suelo segun un poligono

tempe

Temperatura m?nima del mes m?s frio

ppan

Precipitacion anual

ndii

Indice infrarrojo de diferencia normalizado

nvdi

Indice de vegetacion de diferencia normalizado

tempe2

Temperatura m?nima del mes mas calido

ppan2

Precipitacion del mes mas seco

frec.fire

Frecuencia de incendios

perc.fire

Porcentajede la frecuencia de incendios

fireClass

Clase para variable frecuencia de incendio

asp.class

Clase de variable exposicion

eleva.class

Clase de variable numerica elevacion

slope.class

Clase de variable numerica pendiente

ndii.class

Clase de indice infrarrojo de diferencia normalizado

nvdi.class

Clase de indice de vegetacion de diferencia normalizado

Source

Datos fueron cedidos por el Dr Christian Salas-Eljatib (Santiago, Chile).

References

Altamirano A, Salas C, Yaitul V, Smith-Ramirez C, and Avila A. Infuencia de la heterogeneidad del paisaje en la ocurrencia de incendios forestales en Chile Central. Revista de Geografia del Norte Grande, 55:157-170, 2013.

Examples

data(forestFire2)    
head(forestFire2)

Contains information of forest plots across the Hawaiian archipelago.

Description

Diameter at breast height (or occurrence) of individual trees, shrubs and tree ferns across 530 plots across the Hawaiian archipelago and includes native status and cultivated status of the 185 species.

Usage

data(forestHawaii)

Format

Contains 18 variables, as follows:

island

Island name.

plot.id

Unique numeric identifier for each plot.

study

Brief name of study.

plot.area

Plot area in m2^{2}.

longitude

Longitude of plot in decimal degrees; WGS84 coordinate system.

latitude

Latitude of plot in decimal degrees; WGS84 coordinate system.

year

Year in which plot data was collected.

census

Numeric identifier for each census.

tree.id

Unique numeric identifier for each individual.

scientific.name

Genus and species of each individual following TPL v. 1.1.

family

Family of each individual following TPL v. 1.1.

angiosperm

Binary variable (1 = yes, 0 = no) indicating whether an individual is classified as an angiosperm following APG III.

monocot

Binary variable (1 = yes, 0 = no) indicating whether an individual is classified as a monocot following APG III.

native.status

Categorical variable ("native", "alien", "uncertain") indicating alien status of each individual following Wagner et al. (2005).

cultivated.status

Binary variable (1 = yes, 0 = no, NA = not applicable) indicating if species is cultivated following PIER.

abundance

Number of individuals (all = 1).

abundance.ha

Abundance of each individual on a per hectare basis.

dbh

Diameter at 1.3 m (in cm) for each individual; NA indicates that size was not measured, but was classified by size class.

Source

The data were obtained from the DRYAD repository at doi:10.5061/dryad.1kk02qr.

References

- Craven D, Knight T, Barton K, Bialic-Murphy L, Cordell S, Giardina C, Gillespie T, Ostertag R, Sack L,Chase J. 2018. OpenNahele: the open Hawaiian forest plot database. Biodiversity Data Journal 6: e28406.

Examples

data(forestHawaii)    
table(forestHawaii$plot.id)

Function to compute the geometric mean of a vector

Description

Computes the geometric mean of a numeric vector. It is the n-th root of the product of n numbers, as follows.

yg=(i=1nyi)1/ny_g = \left(\prod_{i=1}^{n} y_i\right)^{1/n}

for yi>0y_i > 0. It can also be understood as the average of the logarithmic values of a data set, converted back to a base 10 number. The geometric mean is a central position statistics of a random variable.

Usage

gmean(v)

Arguments

v

is a numeric vector

Details

Notice that can only be computed for positive values. For negative values, there are alternatives, but not covered here.

Value

This function returns the geometric mean, a numeric scalar.

Author(s)

Christian Salas-Eljatib.

Examples

y.var <- runif(10, min=10, max=45)
gmean(y.var)

Diameter growth increments of a tropical tree species in Hawaii

Description

Tree size, competition, and diameter growth increment of Metrosideros polymorpha trees collected in the Kilauea Volcano, Hawaii. Data containing 64 observations at the current annual growth rate (defined as dbh increment within one calendar year) of each tree was measured from 1986 to 1988 using band dendrometers.

Usage

data(hawaii)

Format

The dataframe has the following columns:

tree.code

Tree number identification. The first letter of the ID represents a cohort. Six cohorts representing a chronosequence were sampled.

dbh

Initial stem diameter, in cm.

toth

Total height, in m.

crown.area

Crown outline area, in square meters.

comp.ind

Competition index (Basal area of nearest neighbor divided by square of distance to nearest neighbor plus basal area of second nearest neighbor divided by square of distance to second nearest neighbor).

cai.1986

Current annual stem diameter increment during 1986, in mm.

cai.1987

Current annual stem diameter increment during 1987, in mm.

cai.1988

Current annual stem diameter increment during 1988, in mm.

Source

The data were obtained from Gerrish and Mueller-Dombois (1999).

References

Gerrish G, Mueller-Dombois D. 1999. Measuring stem growth rates for determining age and cohort analysis of a tropical evergreen tree. Pacific Science. 53(4): 418-429.

Examples

data(hawaii)    
head(hawaii)

Incremento corriente anual en diámetro de una especie tropical en Hawaii

Description

Tamaño del árbol, competencia, e incremento corriente anual de árboles de Metrosideros polymorpha colectado en el volcan Kilauea, en Hawaii. Los datos contienen 64 observaciones de incremento corriente anual (definido como el incremento en diámetro en un año calendario) de cada árbol. Estos incrementos fueron medidos desde el año 1986 a 1988 usando bandas dendrometricas.

Usage

data(hawaii)

Format

Estos datos contienen las siguientes columnas:

arb.id

Codigo identificador del árbol. La primera letra del ID representa un cohorte. Hay seis cohortes que representan una cronosecuencia.

dap

Diámetro a la altura del pecho, en cm.

atot

Altura total, en m.

area.copa

Area de copa, en metros cuadrados.

ind.comp

Competition index (Basal area of nearest neighbor divided by square of distance to nearest neighbor plus basal area of second nearest neighbor divided by square of distance to second nearest neighbor).

ica.1986

Incremento corriente anual durante el año 1986, en mm.

ica.1987

Incremento corriente anual durante el año 1987, en mm.

ica.1988

Incremento corriente anual durante el año 1988, en mm.

Source

Los datos fueron obtenidos desde Gerrish and Mueller-Dombois (1999).

References

Gerrish G, Mueller-Dombois D. 1999. Measuring stem growth rates for determining age and cohort analysis of a tropical evergreen tree. Pacific Science. 53(4): 418-429.

Examples

data(hawaii2)    
head(hawaii2)

Tree height growth of Douglas-fir sample trees in the Northwest of the United States

Description

Data contains 148 observations on the height growth of dominant trees of Pseudotsguga mensiezzi in the Northwest of the United States.

Usage

data(hgrdfir)

Format

The data frame contains seven variables as follows:

natfor.id

Code identifier.

plot.code

Plot number identification

tree.code

Tree number identification.

dbh

Diameter at breast height at sampling, in in.

toth

Total height at sa,pling, in ft.

age

Age of tree, yr.

height

Height at a given age, in ft.

Source

The data were provided by Dr Christian Salas.

References

- Monserud RA. 1984. Height growth and site index curves for Inland Douglas-fir based on stem analysis data and forest habitat type. Forest Science 30(4):943-965.

- Salas C, Stage AR, and Robinson AP. 2008. Modeling effects of overstory density and competing vegetation on tree height growth. Forest Science 54(1):107-122. doi:10.1093/forestscience/54.1.107

Examples

data(hgrdfir)    
head(hgrdfir)
unique(hgrdfir$tree.code)
table(hgrdfir$plot.code,hgrdfir$tree.code)
tapply(hgrdfir$dbh, hgrdfir$tree.code, mean)
tapply(hgrdfir$dbh, hgrdfir$tree.code, mean) #dbh of each sample tree
tapply(hgrdfir$toth, hgrdfir$tree.code, mean) #toth of each sample tree

Crecimiento en altura de una muestra de árboles en los Estados Unidos

Description

Data contiene 148 obserrvaciones sobre el crecimiento en altura de árboles dominantes de Pseudotsguga mensiezzi en el Nor-Oeste de los Estados Unidos

Usage

data(hgrdfir2)

Format

La data frame contiene siete variables:

bosque.id

Codigo identificador del bosque.

parcela

Codigo identificador de la parcela.

arbol

Número de identificacion árbol.

dap

Diámetro a la altura del pecho, en pulgadas.

atot

Altura total, en pies

edad

Edad, en os

altura

Altura para cada edad del árbol, en pies

Source

La data fue cedida por el Dr Christian Salas-Eljatib.

References

Monserud RA. 1984. Height growth and site index curves for Inland Douglas-fir based on stem analysis data and forest habitat type. Forest Science 30(4):943-965.

Salas C, Stage AR, and Robinson AP. 2008. Modeling effects of overstory density and competing vegetation on tree height growth. Forest Science 54(1):107-122. doi:10.1093/forestscience/54.1.107

Examples

data(hgrdfir2)    
head(hgrdfir2)
unique(hgrdfir2$arbol.id)
table(hgrdfir2$parcela,hgrdfir2$arbol.id)
tapply(hgrdfir2$dap, hgrdfir2$arbol.id, mean) #dap de cada arbol muestra
tapply(hgrdfir2$atot, hgrdfir2$arbol.id, mean) #atot de cada arbol muestra

Tree height-diameter data from Idaho (USA)

Description

These data are forest inventory measures from the Upper Flat Creek stand of the University of Idaho Experimental Forest, dated 1991.

Usage

data(idahohd)

Format

Contains five variables, as follows:

plot

Plot number.

tree

Tree within plot.

species

A factor with levels DF = Douglas-fir, GF = Grand fir, SF = Subalpine fir, WL = Western larch, WC = Western red cedar, WP = White pine.

dbh

Diameter 137 cm perpendicular to the bole, cm.

toth

Height of the tree, in m.

Source

The data were assembled from the 'ufc' dataframe from the 'alr4' library.

References

Weisberg S. 2014. Applied Linear Regression. 4th edition. New York: Wiley.

Examples

data(idahohd)    
head(idahohd) 
plot(toth~dbh, data=idahohd)

Altura-diámetro de árboles en el estado de Idaho (USA)

Description

Estos datos provienen de un muestreo en el bosque experimental de la University of Idaho, en Upper Flat Creek, Idaho, USA. Medido en 1991.

Usage

data(idahohd2)

Format

Contiene cinco variables detalladas a continuación:

parce

Número de la parcela de muestreo.

arbol

Número del árbol dentro de la parcela.

spp

Especie del árbol, una variable factor con niveles DF = Douglas-fir, GF = Grand fir, SF = Subalpine fir, WL = Western larch, WC = Western red cedar, WP = White pine.

dap

Diámetro del fuste a los 1.3 m sobre el suelo, en cm.

atot

Altura del árbol, en m.

Source

Los datos fueron obtenidos desde la dataframe 'ufc' de la librería 'alr4'.

References

Weisberg S. 2014. Applied Linear Regression. 4th edition. New York: Wiley.

Examples

data(idahohd2)    
head(idahohd2)
plot(atot~dap, data=idahohd2)

Contains regeneration microsite data in Robinson Crusoe Island forest

Description

These are plot-level measurement (2x2 m) data from the forests in the Robinson Crusoe Island, located in the Pacific Ocean, 667 km from mainland Chile. Measurements were collected in transects of 100 to 240 meters in which, 398 squared plots (2x2 m) were set to include canopy gaps, gap borders and closed forest conditions.

Usage

data(invasivesRCI)

Format

Data has the following columns

plot.id

Plot identification code

Gap.type

Canopy gap classified as invaded=Inv, non invaded= Nat or treated =Treat(considering the estimated cover of invasive plant species)

Forest.zone

Location of the plot (gap, border or forest)

Ferns

Estimated cover of fern species (in 2x2 plots)

Moss.liverw

Estimated cover of mosses and liverworts ( in 2x2 plots)

Cwd

Estimated cover of coarse woody debris > 3 cm diameter ( in 2x2 plots)

Litter

Estimated cover of litter (in 2x2 plots)

Ms

Estimated cover of mineral soil ( in 2x2 plots)

Rock

Estimated cover of rocks (in 2x2 plots)

Est.age

Age category for the canopy gap associated to each plot

Source

The data are provided courtesy of Prof. Rodrigo Vargas-Gaete at Universidad de La Frontera (Temuco, Chile).

References

Vargas-Gaete R, Salas-Eljatib C, Gärtner SM, Vidal OJ, Bannister JR, Pauchard A. 2018. Invasive plant species thresholds in the forests of Robinson Crusoe Island, Chile. Plant Ecology & Diversity, 11(2), 205-215.


Computes the sample kurtosis of a distribution

Description

The kurtosis is about the tailedness, or the degree of heaviness of the tails, in the frequency distribution. The function computes an estimator of the kurtosis.

Usage

kurto(x, na.rm = TRUE)

Arguments

x

a numeric vector of a random variable.

na.rm

logical operator to remove NA values. The default is set to TRUE.

Details

The kurtosis of a random variable is the fourth moment of the standardized variable. There are several ways of parameterizing a kurtosis estimator, such as depending on the fourth moment and the standard deviation of the random variable.

Value

An estimator of the kurtosis.

Author(s)

Christian Salas-Eljatib

Examples

y.var<-rnorm(100);x.var<-rbeta(100,.2,2)
kurto(y.var)
kurto(x.var)

Land-cover, environmental and sociodemographic data for the 34 municipalities composing the Greater Santiago area, Santiago, Chile.

Description

dataset contains 476 observations, 34 categorical and 442 numerical. Land-cover data was generated through remote sensing classification techniques using Sentinel-2 satellite images from year 2016. Temperatures were obtained from TIRS band 10 of Landsat 8 satellites images. Particulate matter concentrations were estimated using spatial modelling techniques from 10 pollution stations distributed in the city. Altitude was generated from a Digital Elevation Model. Population and poverty were gathered from Casen 2017 survey.

Usage

data(landCoverSantiago)

Format

The data frame contains four variables as follows:

Comuna

Name of Municipality

p.Construido

Percentage of surface covered by built-up area

p.Vegetacion

Percentage of surface covered by vegetation

p.Desnudo

Percentage of surface covered by bare soil

p.Pasto

Percentage of surface covered by deciduous vegetation

p.Deciduo

Percentage of surface covered by evergreen vegetation

p.Siempreverde

Percentage of surface covered by evergreen vegetation

Temp Invierno

Land surface temperature in celsius degrees at 2pm on a winter 0% cloud day

Temp Verano

Land surface temperature in celsius degrees at 2pm on a summer 0% cloud day

PM10 Invierno

Average particulate matter 10 micron during winter months

PM10 Verano

Average particulate matter 10 micron during summer months

p.pobreza 2017

Percentage of people under poverty line year 2017

Altitud promedio

Average altitude of municipal area

Poblacion

Total population of municipality

Source

Data were provided by Dr Ignacio Fernandez at Universidad Adolfo Ibanez (Santiago, Chile).

References

Not yet

Examples

data(landCoverSantiago)    
head(landCoverSantiago)

Cobertura territorial, ambiental y sociodemografica de los 34 municipios que componen el area del Gran Santiago, Santiago, Chile..

Description

El conjunto de datos contiene 476 observaciones, 34 categoricas y 442 numericas. Los datos de cobertura terrestre se generaron mediante tecnicas de clasificacion de teledeteccion utilizando imagenes de satelite Sentinel-2 del año 2016. Las temperaturas se obtuvieron de la banda TIRS 10 de las imagenes de los satelites Landsat 8. Las concentraciones de material particulado se estimaron mediante tecnicas de modelado espacial de 10 estaciones de contaminacion distribuidas en la ciudad. La altitud se genero a partir de un modelo de elevacion digital. La poblacion y la pobreza se obtuvieron de la encuesta Casen 2017.

Usage

data(landCoverSantiago2)

Format

Variables se describen a continuacion:

Comuna

Name of Municipality

p.Construido

Porcentaje de superficie cubierta por area construida

p.Vegetacion

Porcentaje de superficie cubierta por vegetacion

p.Desnudo

Porcentaje de superficie cubierta por suelo desnudo

p.Pasto

Porcentaje de superficie cubierta por cesped

p.Deciduo

Porcentaje de superficie cubierta por vegetacion de hoja caduca

p.Siempreverde

Porcentaje de superficie cubierta por vegetacion siempre verde

Temp Invierno

Temperatura de la superficie terrestre en grados celsius a las 2 p.m.en un dia de invierno con 0% de nubes

Temp Verano

Temperatura de la superficie de la tierra en grados celsius a las 2 p.m.en un dia de verano con 0% de nubes

PM10 Invierno

Material particulado promedio de 10 micrones durante los meses de invierno

PM10 Verano

Material particulado promedio de 10 micrones durante los meses de verano

p.pobreza 2017

Porcentaje de personas por debajo de la linea de pobreza año 2017

Altitud promedio

Altitud media del termino municipal

Poblacion

poblacion total del municipio

Source

Los datos fueron cedidos por el Dr Ignacio Fernandez de la Universidad Adolfo Ibanez (Santiago, Chile).

References

Not yet

Examples

data(landCoverSantiago2)    
head(landCoverSantiago2)

Contains species composition data of Prumnopitys andina (Lleuque) forests

Description

Contains species composition data for forests with presence of Lleuque (Prumnopitys andina)

Usage

lleuque

Format

The dataframe has the following columns

stand

Stand number

plot.num

Plot number

Aus.chi

Tree density/ha of Austrocedrus chilensis

May.dis

Tree density/ha of Maytenus disticha

Not.obl

Tree density/ha of Nothofagus obliqua

Pru.and

Tree density/ha of Prumnopitys andina

Source

The data are provided courtesy of Prof. Rodrigo Vargas-Gaete at Universidad de La Frontera (Temuco, Chile).

References

Vargas-Gaete R, Salas-Eljatib C, Penneckamp D, Neira Z, Diez MC, Vargas-Picón, R. 2020. Estructura y regeneración de bosques de Prumnopitys andina en los Andes del sur de Chile. Gayana Botánica, 77(1), 48-58.


Computes a likelihood ratio test between a reduced model and a full model

Description

Computes a likelihood ratio test between a reduced model (modr) and a full model (modf). Both models must be previously fitted by maximum likelihood.

Usage

lrt(modr, modf)

Arguments

modr

is a previously fitted model having less parameters than modf

modf

is a previously fitted model having more parameters than modr

Details

Double-check the order of the reduced and full model, before of using the model

Value

This function returns an object having the following elements: "loglik.Modr" maximized log-likelihood of modr; "loglik.Modf" maximized log-likelihood of modf; "dif.loglik" difference in log-likelihood between both models, and "dif.df" difference in degrees of freedong of both models, and "p-value" is the p-value for the LRT.

Author(s)

Christian Salas-Eljatib.

References

Pinheiro JC, and Bates DM. 2000. Mixed-effects models in S and Splus. Springer-Verlag, New York, NY. 528 p.

Examples

#not yet implemented

Computes the mode

Description

Computes the mode of a random variable.

Usage

moda(y = y)

Arguments

y

is a numeric vector.

Details

The mode is an statistics representing the most "used" value of the random variable as a way of central position.

Value

The function returns the mode, a numeric scalar.

Author(s)

Christian Salas-Eljatib.

Examples

set.seed(1234)
variable <- rnorm(10, mean=45,sd=6)
#using the function
moda(y=variable)
moda(variable)

Tree volume for Pinus pinaster in the Baixo-Mino, Galicia, Spain.

Description

These are volume measurements data of sample trees in the Baixo-Mino region in Galicia, Spain.

Usage

data(pinaster)

Format

Contains tree-level variables, as follows:

stand

stand number from the sample tree was selected.

si

Site index of the stand.

tree.no

tree number.

dbh

Diameter at breast height, in cm.

toth

Total height, in m.

d4

Upper-stem diameter at 4 m, in cm.

volwb

Tree gross volume, in m3^{3} with bark.

volwob

Tree gross volume, in m3^{3} without bark.

Source

The data are provided courtesy of Dr Christian Salas-Eljatib at the Universidad de Chile (Santiago, Chile).

References

- Salas C, Nieto L, Irisarri A. 2005. Modelos de volumen para Pinus pinaster Ait. en la comarca del Baixo Mino, Galicia, España. Quebracho 12: 11-22. https://eljatib.com/publication/2005-12-01_modelos_de_volumen_p/

Examples

data(pinaster)    
head(pinaster)

Volumen individual de árboles de Pinus pinaster en Galicia, España.

Description

Variables de volumen y otras a nivel de árbol para una muestra de árboles de Pinus pinaster en la comarca del Baixo-Mino en Galicia, España.

Usage

data(pinaster2)

Format

Contiene las siguientes variables a nivel de árbol:

rodal

Rodal desde donde el árbol fue muestreado

ind.sitio

Indice de sitio del rodal, en m.

arbol

Número del árbol.

dap

Diámetro a la altura del pecho, en cm.

atot

Altura total, en m.

d4

Diámetro fustal a los 4 m, en cm.

vtcc

Volumen bruto total con corteza, en m3^{3}.

vtsc

Volumen bruto total sin corteza, en m3^{3}.

Source

Los datos fueron cedidos por el Dr Christian Salas (Chile).

References

- Salas C, Nieto L, Irisarri A. 2005. Modelos de volumen para Pinus pinaster Ait. en la comarca del Baixo Mino, Galicia, España. Quebracho 12: 11-22. https://eljatib.com/publication/2005-12-01_modelos_de_volumen_p/

Examples

data(pinaster2)    
head(pinaster2)

Contains spatial location of Pinus contorta trees in sample plots.

Description

These are tree-level measurement data, with cartesian location of each tree, from Pinus contorta invasion in Patagonian steppe in Coyhaique in southhern Chile, measured in 2011. There are 3 plots, each of 10.000 m2^{2}.

Usage

data(pinusContorta)

Format

Contains eight variables, as follows:

plot.id

Plot sample ID.

tree.id

Tree identificator number in each plot. Same indv/id for multi-stem trees.

y.coord

coordinate of S latitude.

x.coord

coordinate of W longitude.

substrate

Ground cover in which each pine grow. Bare soil, Festuca pallescens, Baccharis magellanica, Oreopulus glacialis, Acaena integerrima and others species.

drc

Diameter at the root collar on trees, in mm.

h

Height of trees, in cm.

canopy.area

Proyection of canopy area of each tree, in square meters.

Source

The data are provided courtesy of Drs Anibal Pauchard and Rafael Garcia at the Laboratorio de Invasiones Biologicas, Universidad de Concepción (Concepción, Chile).

References

Pauchard A, Escudero A, Garcia RA, de la Cruz M, Langdon B, Cavieres LA, Esquivel J. 2016. Pine invasions in treeless environments: dispersal overruns microsite heterogeneity. Ecology and Evolution. 6(2): 447-459. doi:10.1002/ece3.1877

Examples

data(pinusContorta)    
head(pinusContorta)
unique(pinusContorta$plot.id)

Ubicación espacial de árboles de Pinus contorta en parcela de muestreo

Description

Mediciones a nivel de árbol, con la ubicación cartesian de cada árbol de Pinus contorta, en parcelas de muestreo para estudio de invasion en la estepa Patagonica en Coyhaique en el sur de Chile. Hay tres parcelas, cada una de 10.000 m2^{2}.

Usage

data(pinusContorta2)

Format

Contiene ocho variables, como siguen:

parcela

Parcela.

arbol

Número de árbol en cada parcela. Mismo árbol/id para árboles multifustales.

coord.y

coordinada de latitud W.

coord.x

coordinada de longitud W.

substrato

Cobertura del suelo donde cada pino crece. Bare soil, Festuca pallescens, Baccharis magellanica, Oreopulus glacialis, Acaena integerrima and others species.

h

Height of trees, in cm.

diam.cuello

Diámetro del cuello, en mm.

area.copa

Area de copa, en m2^{2}.

Source

Los datos fueron cedidos por los Drs. Anibal Pauchard y Rafael Garcia del Laboratorio de Invasiones Biologicas, Universidad de Concepcion (Chile).

References

Pauchard A, Escudero A, Garcia RA, de la Cruz M, Langdon B, Cavieres LA, Esquivel J. 2016. Pine invasions in treeless environments: dispersal overruns microsite heterogeneity. Ecology and Evolution. 6(2): 447-459. doi:10.1002/ece3.1877

Examples

data(pinusContorta2)    
head(pinusContorta2)
unique(pinusContorta2$plot.id)

Tree-level variables of several sample plots of invasive Pinus spp in Chile.

Description

These are tree-lavel measurement data from Pinus spp invasion in Araucaria-Nothofagus forests in the Malalcahuello National Reserve in La Araucania region in southhern Chile, measured in 2012. There are 26 plots and plot size is 100 m2^{2}.

Usage

data(pinusSpp)

Format

Contains eight variables, as follows:

plot.id

Plot sample ID.

plot.size

Plot size, en m2^{2}.

lat.s

Decimal coordinate of S latitude.

long.w

Decimal coordinate of W longitude.

indv.id

Tree identificator number in each plot. Same indv/id for multi-stem trees.

stem.id

Stem identificator number in each plot.

spp

Specie.

dbh

Diameter at breast-height, in cm.

toth

Total height, in m.

hcb

Height to crown base, in m.

crown.lenght

Crown lenght, in m.

Source

The data are provided courtesy of Drs Anibal Pauchard and Rafael García at the Laboratorio de Invasiones Biológicas, Universidad de Concepcion (Concepción, Chile).

References

Cobar-Carranza A, Garcia R, Pauchard A, Pena E. 2014. Effect of Pinus contorta invasion on forest fuel properties and its potential implications on the fire regime of Araucaria araucana and Nothofagus antarctica forests. Biological Invasions. 16(11): 2273 - 2291. doi:10.1007/s10530-014-0663-8

Examples

data(pinusSpp)    
head(pinusSpp) 
length(unique(pinusSpp$plot.id)) 
boxplot(dbh~plot.id, data=pinusSpp)

Variables a nivel de árbol en parcelas de muestreo de Pinus spp en Chile.

Description

Mediciones a nivel de árbol para estudiar la invasion de Pinus spp en bosques de Araucaria-Nothofagus en la Reserva Nacional Malalcahuello en la region de la Araucania en el sur de Chile. Hay 26 parcelas, y la superficie de cada una es de 100 m2^{2}.

Usage

data(pinusSpp2)

Format

Los datos contienen ocho columnas que se detallan a continuacion:

parcela

Número de la parcela.

sup.parcela

Superficie de la parcela, en m2^{2}.

lat.s

Decimal coordinate of S latitude.

long.w

Decimal coordinate of W longitude.

indv.id

Identificador del árbol en la parcelaeach plot. Same indv/id for multi-stem trees.

fuste.id

Identificador del fuste.

espe

Especie.

dap

Diámetro a la altura del pecho, en cm.

atot

Altura total, en m.

hcc

Altura comienzo de copa, en m.

largo.copa

Largo de copa, en m.

Source

Los datos fueron cedidos por los Drs. Anibal Pauchard y Rafael García del Laboratorio de Invasiones Biológicas, Universidad de Concepción (Concepción, Chile).

References

Cobar-Carranza A, Garcia R, Pauchard A & Pena E. 2014. Effect of Pinus contorta invasion on forest fuel properties and its potential implications on the fire regime of Araucaria araucana and Nothofagus antarctica forests. Biological Invasions. 16(11): 2273-2291. doi:10.1007/s10530-014-0663-8

Examples

data(pinusSpp2)    
head(pinusSpp2) 
length(unique(pinusSpp2$parce)) 
boxplot(dap~parce, data=pinusSpp2)

Maximum plant size in the Hawaiian archipelago.

Description

Maximum plant size of 58 tree, shrub and tree fern species that occur in 530 forest plots across the Hawaiian archipelago.

Usage

data(plantsHawaii)

Format

Contains six variables, as follows:

scientific.name

Genus and epithet of each individual following The Plant List v. 1.1 (2013).

family

Family of each individual following The Plant List v. 1.1 (2013).

native.status

Categorical variable ('native', 'alien', 'uncertain') indicating alien status of each individual following Wagner et al. (2005).

n

Number of individuals used to estimate maximum plant size.

d.95

Maximum plant size, estimated as D950.1 (King et al. 2006).

d.max.3

Maximum plant size, estimated as Dmax3 (King et al. 2006).

Source

The data were obtained from the DRYAD repository at doi:10.5061/dryad.1kk02qr.

References

- Craven D, Knight T, Barton K, Bialic-Murphy L, Cordell S, Giardina C, Gillespie T, Ostertag R, Sack L,Chase J. 2018. OpenNahele: the open Hawaiian forest plot database. Biodiversity Data Journal 6: e28406.

Examples

data(plantsHawaii)    
head(plantsHawaii)

Presence or absence of sea ice from logbook records of annual cruises

Description

Data containing 52717 observations about presence of sea ice from logbook records of annual cruises to the B-C-B in an unbroken record between years 1850 to 1910.

Usage

data(presenceIce)

Format

The dataframe contains the following columns:

ship.id

The code number for ships.

move.type

Type of movement of ships. 0 indicates a sail-powered vessel and 1 indicates an auxiliary-powered vessel.

year

Year of registry.

month

Month of registry.

day

Day of registry.

lat.dec

Decimal latitude.

long.dec

Decimal longitude.

e.w

East or west of the Prime Meridian.

ice.cov

Sea Ice Observed. 0 no see (Not registered) and 1 presence sea ice (Registered).

Source

The data were provided from Sea Ice Group at the Geophysical Institute.

References

Mahoney A, Bockstoce J, Botkin D, Eicken H, Nisbet R. 2011. Sea-Ice Distribution in the Bering and Chukchi Seas: Information from Historical Whaleships' Logbooks and Journals ARCTIC. 64(4): 465-477.

Examples

data(presenceIce)    
head(presenceIce)

2021 presidential election in Chile.

Description

Voter table-level data of the 2021 presidential election in Chile. The election was held on December 19, 2021.

Usage

data(presidentChile)

Format

The dataframe contains the following columns:

region.no

Administrative region number of Chile.

region

Administrative region name.

province

Province.

senat.const

Senatorial constituency.

distrit

Distrit.

county

County.

elect.const

Electoral constituency.

location

Location.

table

Voter table.

table.type

Voter table type.

merged.tab

Merged voter tables.

electors

Electors.

num.in.vote

.

candidate

Candidate. Gabriel Boric and Jose A. Kast

total.votes

Total number of votes acording to the TRICEL.

Source

The data were obtained from the electoral service of the Chilean Government (SERVEL) at https://www.servel.cl. The datafile name was "Resultados_mesa_presidencial_TRICEL_2v_2021-1.xlsx", and was downloaded on October 24, 2022.

Examples

data(presidentChile)    
head(presidentChile)

Eleccion presidencial del 2021 en Chile.

Description

Datos de mesa de la eleccion presidencial del 2012 en Chile. La eleccion se llevo a cabo el 19 de Diciembre del 2021.

Usage

data(presidentChile2)

Format

Los datos contienen las siguientes columnas:

region.no

Número de la region adminsitrativa de Chile.

region

Nombre de la region administrativa de Chile

provincia

Provincia.

circu.senatorial

Circunscripcion senatorial.

distrito

Distrit.

comuna

County.

circu.elec

Circunscripcion electoral.

local

Local de votacion. Generalmente es un colegio.

no.mesa

Número de mesa.

tipo.mesa

Tipo de mesa de votacion.

mesas.fusionadas

Mesa de votacion fucionada.

electores

Electores.

nro.en.voto

.

candidato

Candidato, ya sea Gabriel Boric o Jose A. Kast

votos.tricel

Número total de votos segun el TRICEL (Tribunal calificador de elecciones).

Source

Los datos fueron obtenidos desde el sitio web del Servicio Electoral del Gobierno de Chilean (SERVEL) en https://www.servel.cl. El archivo de datos descargado el 24 de Octubre del 2022 tenia el nombre "Resultados_mesa_presidencial_TRICEL_2v_2021-1.xlsx".

Examples

data(presidentChile2)    
head(presidentChile2)

2021 primary election for the president of Chile

Description

Voter table-level data of the 2021 primary election for the president of Chile.

Usage

data(primary)

Format

The dataframe contains the following columns:

region.no

Administrative region number of Chile.

region

Administrative region name.

province

Province.

distrit

Distrit.

county

County.

elect.const

Electoral constituency.

location

Location.

table.type

Voter table type.

table

Voter table.

merged.tab

Merged voter tables.

num.in.vote

.

list

Specific political list.

pact

Specific political pact.

party

Political party.

candidate

Candidate name

total.votes

Total number of votes.

Source

The data were obtained from the electoral service of the Chilean Government (SERVEL) at https://www.servel.cl. The datafile name was "Resultados_Primarias_Presidenciales_2021_CHILE.xlsx", and was downloaded on October 24, 2022.

Examples

data(primary)    
head(primary)

Elección primaria para la presidencia de Chile

Description

Datos a nivel de mesa para la votacion primaria de presidente de Chile.

Usage

data(primary2)

Format

The dataframe contains the following columns:

region.no

Región administrativa de Chile.

region

Administrative region name.

provincia

Provincia.

distrito

Distrito.

comuna

Comuna.

circu.elec

Circunscripcion electoral.

local

Local de votacion.

tipo.mesa

Voter table type.

mesa

Voter table.

mesas.fusionadas

Merged voter tables.

nro.voto

.

lista

Lista politica del candidato.

pacto

Pacto politico del candidato.

partido

Partido politica del candidato.

candidato

Nombre del candidato.

votos

Número total de votos.

Source

The data were obtained from the electoral service of the Chilean Government (SERVEL) at https://www.servel.cl. The datafile name was "Resultados_Primarias_Presidenciales_2021_CHILE.xlsx", and was downloaded on October 24, 2022.

Examples

data(primary2)    
head(primary2)

Tree locations for a sample plot in the Llancahue experimental forest

Description

The Cartesian position, species, and diameter of trees within a plot were measured. The sample plot is rectangular of 130 m by 70 m. Further details can be #' reviewed in the reference.

Usage

data(pspLlancahue)

Format

Contains tree-level variables, as follows:

tree.code

Tree identificator

spp

species abreviation as follows: AP= Aextocicon puncatatum, EC=Eucryphia cordifolia, GA=Gevuina avellana, LP= Laureliopsis philippiana, LS= Laurelia sempervirens, ND=Nothofagus dombeyi, Ot=Other, PS=Podocarpus saligna

dbh

diameter at breast height, in cm

x.coord

Cartesian position in the X-axis, in m

y.coord

Cartesian position in the Y-axis, in m

Source

The data are provided courtesy of Prof. Daniel Soto at Universidad de Aysen (Coyhaique, Chile).

References

- Soto DP, Salas C, Donoso PJ, Uteau D. 2010. Heterogeneidad estructural y espacial de un bosque mixto dominado por Nothofagus dombeyi despues de un disturbio parcial. Revista Chilena de Historia Natural 83(3): 335-347.

Examples

data(pspLlancahue)    
head(pspLlancahue) 
descstat(pspLlancahue$dbh)
boxplot(dbh~spp, data=pspLlancahue)

Ubicación cartesiana de árboles en el bosque de Llancahue

Description

Corresponde a la posición cartesiana, especie, y diámetro de árboles en una parcela de muestreo en el bosque de Llancahue, cerca de Valdivia, Chile. La parcela es rectangular con dimensiones de 130 m por 70 m. Mayores antecedentes aparecen en las referencias.

Usage

data(pspLlancahue2)

Format

Contains tree-level variables, as follows:

arb.id

Identificador del árbol.

spp

Codificación de la especie como sigue: AP= Aextocicon puncatatum, EC=Eucryphia cordifolia, GA=Gevuina avellana, LP= Laureliopsis philippiana, LS= Laurelia sempervirens, ND=Nothofagus dombeyi, Ot=Other, PS=Podocarpus saligna.

dap

Diámetro a la altura del pecho, en cm.

coord.x

Posición cartesiana en el eje-X, en m.

coord.y

Posición cartesiana en el eje-Y, en m.

Source

Los datos fueron cedidos por el Prof. Daniel Soto de Universidad de Aysen (Coyhaique, Chile).

References

- Soto DP, Salas C, Donoso PJ, Uteau D. 2010. Heterogeneidad estructural y espacial de un bosque mixto dominado por Nothofagus dombeyi después de un disturbio parcial. Revista Chilena de Historia Natural 83(3): 335-347.

Examples

data(pspLlancahue2)    
head(pspLlancahue2) 
descstat(pspLlancahue2$dap)
boxplot(dap~spp, data=pspLlancahue2)

Tree spatial coordinates in the Rucamanque forest

Description

Tree-level variables and spatial coordinates in a permanent sample plot of 1 ha (100 x 100m) in the Rucamanque experimental forest, near Temuco, Chile.

Usage

data(pspRuca)

Format

The data frame contains four variables for the standing-alive trees as follows:

tree.no

tree number

species

Species name, "N. obliqua" is Nothofagus obliqua, "Ap" is Aexitocicum puncatatum, etc.

crown.class

Crown class (1: superior, 2: intermediate, 3; inferior)

dbh

diameter at breast-height, in cm

x.coord

Cartesian position at the X-axis, in m

y.coord

Cartesian position at the Y-axis, in m

Source

Data were provided by Dr Christian Salas-Eljatib (Universidad de Chile, Santiago, Chile).

References

Salas C, LeMay V, Nunez P, Pacheco P, and Espinosa A. 2006. Spatial patterns in an old-growth Nothofagus obliqua forest in south-central Chile. Forest Ecology and Management 231(1-3): 38-46. doi:10.1016/j.foreco.2006.04.037

Examples

data(pspRuca)    
head(pspRuca) 
table(pspRuca$species)

Ubicación espacial de árboles en el bosque de Rucamanque

Description

Medidas a nivel de árbol y coordenadas espaciales en un parcela de muestreo permanente de 1 ha (100 x 100m) en el bosque de Rucamanque, cerca de Temuco, Chile. Mayores antecedentes en las referencias.

Usage

data(pspRuca2)

Format

Las columnas describen características de los árboles vivos en pie, como sigue:

arbol

Número del árbol

especie

Nombre de la especie, "N. obliqua" es Nothofagus obliqua, "Ap" es Aexitocicum puncatatum, etc.

clase.copa

Clase de copa (1: superior, 2: intermedio, 3; inferior)

dap

Diámetro a la altura del pecho, en cm

coord.x

Posicion cartesiana en el eje X, en m

coord.y

Posicion cartesiana en el eje Y, en m

Source

Los datos fueron cedidos por el Dr Christian Salas-Eljatib (Santiago, Chile).

References

Salas C, LeMay V, Nunez P, Pacheco P, and Espinosa A. 2006. Spatial patterns in an old-growth Nothofagus obliqua forest in south-central Chile. Forest Ecology and Management 231(1-3): 38-46. doi:10.1016/j.foreco.2006.04.037

Examples

data(pspRuca2)    
table(pspRuca2$especie)

Height growth of Pinus taeda (Loblolly pine) trees

Description

The Loblolly data frame has 84 rows and tree columns of records of the tree height growth of Loblolly pine trees. This dataframe is a slight modification to the original dataframe "Loblolly" from the datasets R package.

Usage

data(ptaeda)

Format

An object of class c("nfnGroupedData", "nfGroupedData", "groupedData", "data.frame") containing the following columns:

seed.id

an ordered factor indicating the seed source for the tree. The ordering is according to increasing maximum height.

age

a numeric vector of tree ages, in yr.

toth

a numeric vector of tree heights, in m.

Source

Pinheiro, J. C. and Bates, D. M. (2000) Mixed-effects Models in S and S-PLUS. Springer.

Examples

data(ptaeda)
plot(toth ~ age, data = ptaeda, subset = seed.id == 329,
     xlab = "Age (yr)", las = 1,
     ylab = "Height (m)")

Crecimiento en altura de Pinus taeda

Description

Esta dataframe contiene 84 folas y tres columnas de crecimiento en altura de árboles de Pinus taeda (Loblolly pine). Es una modificación de la dataframe "Loblolly" del paquete 'datasets' de R.

Usage

data(ptaeda2)

Format

An object of class c("nfnGroupedData", "nfGroupedData", "groupedData", "data.frame") containing the following columns:

semilla.id

Un factor indicando el origen de la semilla del árbol.

edad

Edad del árbol, en años.

atot

Altura total, en m.

Source

Pinheiro, J. C. and Bates, D. M. (2000) Mixed-effects Models in S and S-PLUS. Springer.

Examples

data(ptaeda2)
plot(atot ~ edad, data = ptaeda2, subset = semilla.id == 329,
     xlab = "Edad (años)", las = 1,
     ylab = "Altura (m)")

Obtain the P-value for a Standard t-distributed random variable

Description

Function to compute the P-value for a Standard t-distributed random variable.

Usage

pvalt(t.value, df, decnum = 5)

Arguments

t.value

A numeric random variable following a t-student pdf distribution.

df

degrees of freedom of the random variable following a t-student pdf distribution.

decnum

the number of decimals to be used in the output. The default is set to 5.

Details

It is suited to compute the P-value for any random variable following a Standard t probability density function. For instance, to obtain the p-value in a t-test.

Value

The function returns the P-value or probability of getting a value as large as t.value.

Author(s)

Christian Salas-Eljatib

Examples

## Load dataset
df <- datana::araucaria
#
## Computes the t-test statistics (from the 'stats' package)
t.value <- stats::t.test(df$hdom)
t.v <- as.numeric(t.value$statistic)
deg.f <- as.numeric(t.value$parameter)

## Obtaining the p value
pvalt(t.v,deg.f)

Obtain the P-value for a Standard Gaussian random variable

Description

Function to computes the P-value for a Standard Gaussian random variable.

Usage

pvalz(zval, decnum = 5)

Arguments

zval

A numeric random variable following a Standard Gaussian distribution.

decnum

the number of decimals to be used in the output. The default is set to 5.

Details

It is suited to compute the P-value for any random variable following a Standard Gaussian probability density function.

Value

This function returns the P-value or probability of getting a value as large as 'zval'.

Author(s)

Christian Salas-Eljatib

Examples

pvalz(1.96)

Sampling plots data from a Pinus radiata plantation near Capitan Pastene, Region de La Araucania, Chile.

Description

Tree-level information collected within sample plots in a forestry plantation of Pinus radiata near Capitan Pastene, Southern Chile. Sample plots size is 150 150 m2^{2}.

Usage

data(radiatapl)

Format

The data frame contains four variables as follows:

plot

Plot number identification.

tree

Tree number identification.

dbh

Diameter at breast height, in cm.

heigth

Total height, in m.

Source

The data are provided courtesy of Mr. Mauricio Lobos-Beneventi (Temuco, Chile).

Examples

data(radiatapl)    
head(radiatapl)

Datos a nivel de árbol de parcelas de muestreo en plantaciones de Pinus radiata

Description

Es un listado de árboles con características medidas dentro de unidades de muestreo en una plantacion de Pinus radiata cercana a Capitan Pastene, Region de la Araucania, Chile. Las parcelas de muestreo tienen 150 m2^{2}.

Usage

data(radiatapl2)

Format

Los datos contienen las siguientes columnas

parce

Número de identificación de la parcela de muestreo.

arbol

Número de identificación del árbol dentro de la parcela.

dap

Diámetro a los 1.3 m en el fuste, en cm.

atot

Altura total, en m. Solo registrada para algunos árboles muestra.

Source

Los datos son cortesia del Ing. Forestal Mauricio Lobos-Beneventi (Temuco, Chile).

Examples

data(radiatapl2)    
head(radiatapl2)

Height growth of Nothofagus alpina trees in Chile.

Description

Time series data of height for rauli (Nothofagus alpina) trees in south-central Chile. These sampled trees are part of the ones used in Salas-Eljatib (2021, Ecological Applications). The full citation is provided below.

Usage

data(raulihg)

Format

The data frame contains four variables as follows:

tree.code

tree id code

spp

species common name

bha.t

breast-height age, in yrs.

h.t

total height, in m.

Source

Data were provided by Dr Christian Salas-Eljatib (Santiago, Chile).

References

- Salas-Eljatib C. 2021. An approach to quantify climate-productivity relationships: an example from a widespread Nothofagus forest. Ecological Applications 31(4): e02285. doi:10.1002/eap.2285

- Salas-Eljatib, C. 2021. Time series height-data for Nothofagus alpina trees. doi:10.6084/m9.figshare.13521602.v5

Examples

data(raulihg)    
head(raulihg)

Crecimiento en altura de árboles de Nothofagus alpina.

Description

Datos de series de tiempo de altura para árboles muestreados de Nothofagus alpina (rauli) en el centro-sur de Chile. Estos árboles son parte de los usados en Salas-Eljatib (2021, Ecological Applications). La cita completa se da en referencias.

Usage

data(raulihg2)

Format

Contiene variables de nivel individual, como se describen a continuacion::

tree.code

Codigo del árbol

spp

Nombre comun especie

bha.t

Edad a la altura del pecho, en años.

h.t

Altura total, en m.

Source

Datos cedidos por el Prof. Christian Salas-Eljatib.

References

- Salas-Eljatib C. 2021. An approach to quantify climate-productivity relationships: an example from a widespread Nothofagus forest. Ecological Applications 31(4): e02285. doi:10.1002/eap.2285

- Salas-Eljatib C. 2021. Time series height-data for Nothofagus alpina trees. doi:10.6084/m9.figshare.13521602.v5

Examples

data(raulihg2)    
head(raulihg2)

Contains information about regeneration of Nothofagus seedlings.

Description

Dataset contains 442 observations.

Usage

data(regNothofagus)

Format

Contains 15 variables, as follows:

site

Id site of study.

plot

Number of plot.

scar

Scarification in percentage of total area.

x.trans.total

Transmitted radiation in percentage.

kPa

Soil resistance to penetration.

SWC

Soil water content.

SM

Exposed mineral soil.

litter

Litter cover in percentage.

CWD

Ocular estimation in the regeneration plot in percentage.

MT

Microtopography. 1 plane, 2 convex, 3 concave, 4 mixed (convex and concave) in the regeneration plot.

S

Ground-layer vascular species richness in the regeneration plot..

LLES

Long-lived early-seral tree species (N. dombeyi , N. alpina , Nothofagus pumilio ).

SLES

Short-lived early-seral plants (Ribes spp. and Fuchsia sp).

LLLS

Long-lived late-seral tree species (L. philippiana and Dasyphyllum diacantaoides ).

log.bam

Logarithm of the cover of bamboo (%) in the regeneration plot.

Source

The data were obtained from the DRYAD repository at doi:10.5061/dryad.3q977

References

Soto D, Puettmann K.2018. Topsoil removal through scarification improves natural regeneration in high-graded Nothofagus old-growth forests. Journal Applied Ecology. 55: 967- 976.

Examples

data(regNothofagus)    
head(regNothofagus)

Simulated yield of forestry plantations of exotic species in Chile.

Description

The yield tables of simulated plantations of Pinus radiata, Eucalyptus globulus, and Eucalyptus nitens are obtained from the Radiata simulator and EucaSim simulator built in Chile. Several stand-level variables are part of the output.

Usage

data(simula)

Format

Contains stand-level variables, as follows:

species

"P. radiata" is Pinus radiata, "E. globulus" is Eucalyptus globulus, and "E. nitens" is Eucalyptus nitens.

age

plantation age, in years

tph

Tree density, in trees/ha

gha

Basal area, in m2^{2}/ha

toph

Dominant height, in m

qmd

quadratic mean diameter, in cm

totvol

gross stand volume, in m3^{3}/ha

viu.10

stand volume below an utilizacion index of 10 cm, in m3^{3}/ha

viu.15

stand volume below an utilizacion index of 15 cm, in m3^{3}/ha

viu.20

stand volume below an utilizacion index of 20 cm, in m3^{3}/ha

viu.25

stand volume below an utilizacion index of 25 cm, in m3^{3}/ha

Source

The data were obtained as outputs for plantations without management in Chile. The academic version of the simulator was used. You can visit mnssimulacion.cl

Examples

data(simula)

Computes the skewness of a numeric vector

Description

The skewness is about the departure from symmetry of a frequency distribution. Therefore, It is about asymmetry. One way to assess asymmetry of a random variable is to compute an statistics representing its skewness. The current function an dimensionless statistics of the skewness of given vector.

Usage

skew(x, na.rm = TRUE)

Arguments

x

A numeric vector representing a random variable.

na.rm

Logical value to remove NA values. The default is set to TRUE.

Details

The skewness of a random variable is the third moment of the standardized variable. There are several ways of parameterizing an skewness estimator, such as depending on the third moment and the standard deviation of the random variable.

Value

The value of the the skewness of given vector

Author(s)

Christian Salas-Eljatib.

Examples

y.var<-rnorm(100);x.var<-rbeta(100,.2,2)
skew(y.var)
skew(x.var)

Biomass dataset

Description

Dataset that contains nine pairs of columns with information about biomass of 40 samples.

Usage

data(slashpine)

Format

The data frame contains nine variables as follows:

tree_id

tree code

dbh

diameter

h

heigth

lcl

live crown lenght

age

age tree

wood

wood biomass

bark

bark biomass

crown

crown biomass

tree

tree biomass

Source

Data were provided by Dr Christian Salas-Eljatib (Universidad de Chile, Santiago, Chile).

References

Parresol BR. 2001. Additivity of nonlinear biomass equations. Canadian Journal of For Research, 31:865-878.

Examples

data(slashpine)    
head(slashpine)

Biomasa

Description

Dataset que contiene nueve pares de columnas con informacion sobre la biomasa de 40 árboles.

Usage

data(slashpine2)

Format

Variables se describen a continuación:

tree_id

Identifcador del árbol

dbh

diámetro

h

altura total

lcl

largo de copa

age

edad árbol

wood

biomasa madera

bark

biomasa corteza

crown

biomasa copa

tree

biomasa total

Source

Datos fueron contribuidos por el Dr Christian Salas-Eljatib (Universidad de Chile, Santiago, Chile).

References

Parresol BR. 2001. Additivity of nonlinear biomass equations. Canadian Journal of For Research, 31:865-878.

Examples

data(slashpine2)    
head(slashpine2)

Sludge data are at different cities, with a value of concentration zinc.

Description

Dataset contains 36 observations

Usage

data(sludge)

Format

Contains four variables, as follows:

city

Name of city.

rate

Concentration rate of sludge.

zinc

Value of concentration ( in ppm).

trt.comb

Combination between city and rate factors.

Source

The data were provided from.

References

not yet

Examples

data(sludge)    
head(sludge)

On the National System of State Protected Wild Areas (SNASPE) of Chile.

Description

Dataset contains the protected wild areas of Chile that are part of the National System of State Protected Wild Areas (SNASPE).

Usage

data(snaspeChile)

Format

Contains the following variables:

unit.id

Number for the unit.

unit

Name of the protected area.

category

Category of the unit. It can be either a National Park, a National Reserve or a Natural Monument.

commune

Name of the commune (the smallest Chilean territorial division) where the unit is located.

province

Province where the comunne is located (one territorial division level above the commune).

region

Region where the province is located (one territorial division level above the province and the biggest Chilean territorial division).

perim.km

Perimeter, in km.

area.ha

Area, in hectares.

area.m2

Area, in m2^{2}.

Source

These data is freely available at https://ide.minagri.gob.cl/geoweb/2019/11/21/medio-ambiente/

References

The SNASPE has been created and is currently managed by the National Forest Corporation (CONAF). More information and documentation can be found at https://www.conaf.cl

Examples

data(snaspeChile)    
head(snaspeChile)

Sistema nacional de areas protegidas del estado (SNASPE) de Chile

Description

Contiene variables general de las unidades del sistema de areas protegidas por el estado de Chile (SNASPE).

Usage

data(snaspeChile2)

Format

Contiene las siguientes variables para cada unidad del SNASPE:

uni.id

número indentificador de la unidad.

unidad

Nombre de la unidad.

categoria

Categoría de la unidad. It can be either a National Park, a National Reserve or a Natural Monument.

comuna

Name of the commune (the smallest Chilean territorial division) where the unit is located.

province

Province where the comunne is located (one territorial division level above the commune).

region

Region where the province is located (one territorial division level above the province and the biggest Chilean territorial division).

perim.km

Perimeter, in km.

area.ha

Area, in hectares.

area.m2

Area, in m2^{2}.

Source

Estos datos fueron obtenidos desde https://ide.minagri.gob.cl/geoweb/2019/11/21/medio-ambiente/

References

EL SNASPE esta bajo la administracion de la Corporacion Nacional Forestal (CONAF) de Chile. Mayor informacion y documentacion se puede encontrar en https://www.conaf.cl

Examples

data(snaspeChile2)    
head(snaspeChile2)

Soil treatment experiment in tree seedlings

Description

A test was made of the effect of three soil treatments on the height growth of 2-year-old seedlings. Treatments were assigned at random to the three plots within each of 11 blocks. Each plot was made up of 50 seedlings. Average 5-year height growth was the criterion for evaluating treatments.

Usage

data(soiltreat)

Format

Contains the four following columns, at the plot-level,

block

Block unit.

treat

Treatment level.

ini.h

Initial height, in m.

inc.h

Increment in height during 5-year, in m.

Source

Table in page 71 of Freese (1967). The data were entered by Nayeli Ramirez, a former student of Prof. Christian Salas-Eljatib.

References

- Freese, F 1967. Elementary statistical methods for foresters. Agriculture Handbook 3171, USDA Forest Service.

Examples

data(soiltreat)    
head(soiltreat) 
tapply(soiltreat$inc.h,soiltreat$treat,summary)
tapply(soiltreat$inc.h,soiltreat$treat,sd)

Tratamientos del suelo en el crecimiento de plantulas.

Description

Un experimento sobre el efecto de tres tratamientos del suelo en el crecimiento en altura de plantulas de 2-años de edad. Los tratamientos fueron asignados aleatoriamente a tres parcelas dentro de cada uno de 11 bloques. Cada parcela esta constituida por hasta 50 plantulas. El promedio del incremento en altura de los ultimos 5 años fue la variable de interes para evaluar los tratamientos.

Usage

data(soiltreat2)

Format

Los datos, a nivel de parcela, tienen las siguientes columnas,

bloque

Bloque del experimento.

tmo

Factor tratamiento, medido en tres nivels.

alt.ini

Altura initial, rn m.

alt.inc

Incremento en altura durante los últimos cinco años, en m.

Source

Cuadro de la página 71 de Freese (1967). Los datos fueron digitados por Nayeli Ramirez, una estudiante del Prof. Christian Salas-Eljatib.

References

- Freese, F 1967. Elementary statistical methods for foresters. Agriculture Handbook 3171, USDA Forest Service.

Examples

data(soiltreat2)    
head(soiltreat2) 
tapply(soiltreat2$alt.inc,soiltreat2$tmo,summary)
tapply(soiltreat2$alt.inc,soiltreat2$tmo,sd)

Tree locations for several plots of Norway spruce in Austria

Description

The Cartesian position, species, year, ID tree , and diameter of trees within a plot were measured.

Usage

data(spatAustria)

Format

Contains cartesian position of trees, and covariates, in sample plots, as follows:

plot.code

Plot identificator

tree.code

Tree identificator

spp.name

species abreviation as follows: PCAB=Picea abies, FASY= Fagus sylvatica, QCPE=Quercus petraea , PNSY= Pinus Sylvestris, LADC=Larix decidua

x.coord

Cartesian position in the X-axis, in m

y.coord

Cartesian position in the Y-axis, in m

year

Measurement year

dbh

diameter at breast-height, in cm

References

- Kindermann G. Kristofel F, Neumann M, Rossler G, Ledermann T & Schueler. 2018. 109 years of forest growth measurements from individual Norway spruce trees. Sci. Data 5:180077 doi:10.1038/sdata.2018.77

Examples

data(spatAustria)    
head(spatAustria)
pos<-spatAustria
oldpar<-par(mar=c(4,4,0,0))
bord<-data.frame(x=c(min(pos$x.coord),max(pos$x.coord),min(pos$x.coord),max(pos$x.coord)),
               y=c(min(pos$y.coord),min(pos$y.coord),max(pos$y.coord),min(pos$y.coord)))
plot(bord,type="n", xlab="x (m)", ylab="y (m)", asp=1, bty='n')
points(pos$x.coord,pos$y.coord,col=pos$plot.code,cex=0.5) 
par(oldpar)

Names and other information of plant species (mainly trees)

Description

This data set provides names (taxonomy), of plant species. Includes codes and name abbreviations used by the Biometrics group at the Forest Biometrics and Modelling Lab, Universidad de Chile, Santiago, Chile.

Usage

data(speciesList)

Format

A data frame with 63 observations on 31 variables

nesp

Unique correlative specie number

spp.ci.name

Species scientific name

spp.ci.abb

Species scientific name abbreviation

common.name

Species common name. No blank spaces, no special characters

common.nameBlank

Species common name. With blank spaces, no special characters

esp

Species code: code given by CEM Biometrics to identify species for different processing routines

common.nameLatex

Species common name formatted for Latex

nTaxon

Unique number of the taxon (i.e., species)

kingdom

Taxonomic rank Kingdom. In this datase, all species belong to the Kingdom Plantae

division

Taxonomic rank division or phylum within the Kingdom

class

Taxonomic rank Class within the Kingdom

order

Taxonomic rank Order within the Class

family

Taxonomic rank Family within the Order

spp.ci.full

Full scientific name including author

genus

Taxonomic rank Genus within the Family

epithet

Specific epithet

sppAuthor

Species author

subSpp

Subespecies: one of two or more populations of a species varying from one another by morphological characteristics

subSppAuthor

Subespecies author

varSpp

Species variety or varietas

varSppAuthor

Variety author

formSpp

Form or forma

formSppAuthor

Form author

commonNamesList

List of common names per species, separated by commas

synonyms

Synonyms of the scientific name by which the species has been or is known

borCountries

Border countries given the species distribution range

habit

Habit. The general appearance, growth form, or architecture e.g., tree, shrub, grass

lifeCycle

Life cycle

statusOri

Status according to the species origin: Native or Endemic

regDist

Distribution range of the species, within Chile administrative regions

elevRange

Distribution range of the species, in terms of elevation. Meters above sea level

notes

Notes

Source

Data provided from https://investigacion.conaf.cl/repositorio/documento/ficha-repositorio.php?redo_id=1080946

References

Proyecto 004/2016 Lista sistematica actualizada de la flora vascular nativa de Chile, origen y distribucion geografica. VII Concurso del Fondo de Investigacion del Bosque Nativo


Contains information of abundance of plant species in the central-southern Andes of Chile.

Description

Abundance of plant species [50 total] (at parcel scale [100 m2^{2}]) in burned Araucaria-Nothofagus forests with different levels of fire severity (ie, unburned = unburned, low_sev = low severity, mid_sev = medium severity , high_sev = high severity) in the China Muerta National Reserve, Andes of central-southern Chile.

Usage

data(sppAbundance)

Format

Contains 6 variables, as follows:

sp.name

name of specie.

sp.code.name

code of specie

unburned

Abundance of plants unburned.

low.sev

Abundance of plants for low severity of burned.

mid.sev

Abundance of plants for middle severity of burned.

high.sev

Abundance of plants for high severity of burned.

Source

The data are provided courtesy of Dr Andres Fuentes-Ramirez at the Universidad of La Frontera (Temuco, Chile)

References

- Fuentes-Ramirez A, Salas-Eljatib C, Gonzalez M, Urrutia J, Arroyo P, Santibanez P. 2020. Initial response of understorey vegetation and tree regeneration to a mixed-severity fire in old-growth Araucaria-Nothofagus forests.Applied Vegetation Science. 23:210-222.

Examples

data(sppAbundance)    
head(sppAbundance)

Contains information of functional traits of species.

Description

Dataset contains 48 observations about about functional trait values for each of the 48 study species, including 23 evergreen and 25 deciduous.

Usage

data(sppTraits)

Format

Contains 17 variables, as follows:

sp

Abbreviated name of specie.

sp.name

Name of specie.

family

Family of specie.

genus

Genus of specie.

phyl

Type of phylogeny.

l.hab

Type of leaf habit.

leaf

Type of leaf.

lt

.

lma

Leaf mass area.

amass

Photosynthetic capacity per unit leaf mass.

n.mass

Leaf N content per unit mass.

pmass

Leaf P content per unit mass.

l.lifespan

Leaf life span.

l.length

Leaf length.

sem

Seed mass.

wd

Wood density.

max.h

Maximum height.

Source

The data were provided from DRYAD repository

References

- Ameztegui A, Paquette A, Shipley B, Heym M, Messier C, Gravel D. 2016 . Shade tolerance and the functional trait: demography relationship in temperate and boreal forests. Functional Ecology 31: 821-830.

Examples

data(sppTraits)    
head(sppTraits)

Plot-level data with variables from Andean Prumnopitys forests

Description

Data on density, basal area, mean square diameter and other variables of 24 plots for Lleuque is provided.

Usage

data(standLleuque)

Format

The data frame contains seven variables as follows:

rodal

number of stand

plot.id

code of plot

nha

Density of plot

gha

Basal area of plot

qmd

Quadratic mean diameter of plot

toph

Dominant height of plot

structure

Forest structure level: open, secondary adult, pure

Source

The data are provided courtesy of Prof. Rodrigo Vargas-Gaete at Universidad de La Frontera (Temuco, Chile).

References

Vargas-Gaete R, Salas-Eljatib C, Penneckamp D, Neira Z, Diez MC, Vargas-Picón, R. 2020. Estructura y regeneración de bosques de Prumnopitys andina en los Andes del sur de Chile. Gayana Botánica, 77(1), 48-58.

Examples

data(standLleuque)    
head(standLleuque)

Datos con variables a nivel de parcela de bosques de Prumnopitys andina

Description

Se proporciona informacion de densidad, area basal, diámetro medio cuadratico y otras variables de 24 parcelas para Lleuque.

Usage

data(standLleuque2)

Format

Variables se describen a continuacion::

rodal

Número de rodal

plot.id

Codigo de parcela

nha

Densidad de parcela

gha

Area basal de parcela

qmd

Diámetro medio cuadratico

toph

Altura dominante

estructura

Estructura del bosque. Abiero, secundario adulto o puro

Source

The data are provided courtesy of Prof. Rodrigo Vargas-Gaete at Universidad de La Frontera (Temuco, Chile).

References

Vargas-Gaete R, Salas-Eljatib C, Penneckamp D, Neira Z, Diez MC, Vargas-Picón, R. 2020. Estructura y regeneración de bosques de Prumnopitys andina en los Andes del sur de Chile. Gayana Botánica, 77(1), 48-58.

Examples

data(standLleuque2)    
head(standLleuque2)

Produces a time series plot

Description

Produces a time series plot, of variable 'y' as a function of 'x' by an observational unit factor.

Usage

timeserplot(
  data = data,
  y = y,
  x = x,
  obs.unit = obs.unit,
  factor1 = NA,
  factor2 = NA,
  only.lines = FALSE,
  ylab = NA,
  xlab = NA,
  linetype.lab = NA,
  factor2.line = TRUE,
  factor2.col = FALSE,
  max.y.all = NA,
  levels.i.want = FALSE,
  col.lev.i.want = FALSE,
  col.lines = FALSE
)

Arguments

data

a dataframe with at least tree columns representing the response variable ("y"), the main predictor variable ("x"), and a variable indicating the observational unit ("obs.unit").

y

a character giving the column name of the response variable or variable of interest.

x

a character giving the column name of the main predictor variable. Generally this variable is time.

obs.unit

a character giving the column name containing the info of the observational unit.

factor1

an optional character having the name of a column having a factor variable (e.g., treatment). The detault value is set to NULL.

factor2

an optional character having the name of a column having another factor variable (e.g., species). The detault value is set to NULL.

only.lines

a logic value if only lines, but not including dots, are going to be drwan in the plot. The detault value is set to FALSE.

ylab

Label for the Y-axis

xlab

Label for the X-axis

linetype.lab

is an optional string to be used as the title of the factor being represented by lines. It is only needed if factor1 and factor2 are defined. See example.

factor2.line

a logic value if the second factor, factor2, is going to be segregated according to the type of lines. The detault value is set to TRUE.

factor2.col

a logic value if the second factor, factor2, is going to be segregated according to the color of the lines only. The detault value is set to FALSE.

max.y.all

A number representing the maximum level of Y-axis for all classes

levels.i.want

A vector having the levels for the factor under study

col.lev.i.want

A vector having the colors to be used for the factor under study

col.lines

A string specifying the single color to be used for the lines of the timeseries

Details

Both 'y' and 'x' must be numeric variables, and the column representing the observational unit, must be a factor. This factor identifies the longitudinal context of the data, for instance, a student being measured on time. Besides, two more factors can be added to the plotting details, in order to represent the potential variability among them.

Value

This function returns a time series plot

Note

Please, uses with caution, and run first the examples to understand it better.

Author(s)

Christian Salas-Eljatib

Examples

#data(ficdiamgr)
# df <- ficdiamgr
# 
# timeserplot(df, y="dbh", x="time", obs.unit = "tree")
# timeserplot(df, y="dbh", x="time", obs.unit = "tree", only.lines = T)
# 
# # dos opciones de lo solicitado
# timeserplot(df, y="dbh", x="time", obs.unit = "tree", col.lines = T, only.lines = T)
# timeserplot(df, y="dbh", x="time", obs.unit = "tree", col.lines = T, only.lines = F)
# 
# timeserplot(df, y="dbh", x="time", obs.unit = "tree", factor1="site")
# timeserplot(df, y="dbh", x="time", obs.unit = "tree", factor1="site", factor2= "species")
# timeserplot(df, y="dbh", x="time", obs.unit = "tree", factor1="site", factor2= "species",
#             factor2.col = T, only.lines = T)

Contains information of Camera trap data on medium to large terrestrial mammals collected at 54 camera stations in Ruaha National Park, southern Tanzania.

Description

Dataset contains 14604 observations and sampling was carried out for two months during the dry season of 2013 and two months during the wet season of 2014. Each camera station is associated with a randomly placed camera and a trail-based camer, with the aim of comparing communities resulting from the two camera trap placement strategies.

Usage

data(trailCameraTrap)

Format

Contains 6 variables, as follows:

reference

Number of observation od datasets.

placement

Type of "placement" placed in each station (random or trail).

season

Season where were made the samplings.

station

Station where were collected the data.

specie

Name of specie medium to large terrestrial mammals.

date.time

The date and time of each photographic event is also given.

Source

The data were provided by Dr Jeremy Cusack.

References

- Cusack J, Dickman A, Rowcliffe M, Carbone C, Macdonald D, Coulson T. 2016 . Random versus game trail-based camera trap placement strategy for monitoring terrestrial mammal communities. PLoS ONE 10(5): e0126373.

Examples

data(trailCameraTrap)    
head(trailCameraTrap)

Functional traits of vegetative species in Chile.

Description

Functional traits of vegetative species in Chile. Includes column with codified name (esp)

Usage

data(traits)

Format

esp

species codified name

shadeTolerance

indicates the species tolerance to shape. There are three main classes: shade-tolerant, shade-midtolerant and shade-intolerant

spp.ci.name

Scientific name.

spp.ci.abb.

.

wd

wood density in kg per cubic meters.

Source

Some of the information on shade tolerance can be found in Soto et al 2010.

References

- Soto DP, Salas C, Donoso PJ, Uteau D. 2010. Heterogeneidad estructural y espacial de un bosque mixto dominado por Nothofagus dombeyi despues de un disturbio parcial. Revista Chilena de Historia Natural 83(3): 335-347.


Rasgos funcionales para algunas especies vegetales de Chile.

Description

Rasgos funcionales para algunas especies vegetales de Chile.

Usage

data(traits2)

Format

especie

Codigo alfanumerico para especie.

tolerancia.sombra

Tolerancia a la sombra de la especie.

nombre.cient

Nombre cientifico.

nom.cient.abre

Nombre cientifico abreviado.

den.madera

Densidad de la madera en kg/m3^{3}.

Source

Parte de la informacion sobre tolerancia a la sombra se encuentra en Soto et al 2010

References

- Soto DP, Salas C, Donoso PJ, Uteau D. 2010. Heterogeneidad estructural y espacial de un bosque mixto dominado por Nothofagus dombeyi despues de un disturbio parcial. Revista Chilena de Historia Natural 83(3): 335-347.


Diameter and height growth of Grand-fir (Abies grandis) sample trees

Description

Diameter and height growth of 66 Grand-fir trees. Data derived from stem analysis sample trees collected by Dr Albert Stage (US Forest Service, Moscow, ID, USA.)

Usage

data(treegr)

Format

Contains seven column, as follows:

tree.id

Tree number identificator. An unique number to each sample tree.

forest

Forest type.

habitat

Forest habitat type.

tree.code

A composite tree code representing the following columns: tree.id-forest-habitat

age

Age, in yr

dbh

Diameter at breast-height, in cm.

toth

Total height, in m.

Source

Originally, the data were provided by Dr Albert Stage (R.I.P) to Professor Andrew Robinson (University of Idaho, USA), whom used them to explain the fitting of statistical models. Dr Christian Salas-Eljatib was a former graduate student of Statistics of Prof Robinson at the Univ. of Idaho.

References

Stage, A. R., 1963. A mathematical approach to polymorphic site index curves for Grand fir. Forest Science 9 (2), 167–180.

Examples

data(treegr)    
head(treegr)

Crecimiento en diámetro y altura de árboles muestras de Grand-fir (Abies grandis)

Description

Crecimiento en diámetro y altura de 66 árboles de Grand-fir. Los datos fueron derivados a partir de árboles muestras de analisis fustal colectados por el Dr Albert Stage (US Forest Service, Moscow, ID, USA.)

Usage

data(treegr2)

Format

Contiene las siguientes siete columnas:

num.arb

Número identificador del árbol. Unico para cada árbol muestra.

bosque

Tipo forestal.

habitat

Clasificación de tipo de habitat.

cod.arb

Un código que combina a las siguientes columnas: num.arb-bosque-habitat

edad

Edad, en años.

dap

Diámetro a la altura del pecho, en cm. Note que los decimales es debido a que esta variable originalmente fue medida en pulgadas.

atot

Altura total, in m. Note que los decimales es debido a que esta variable fue originalmente medida en pies.

Source

Originalmente los datos fueron cedidos por el Dr Albert Stage (Q.E.P.D) al Profesor Andrew Robinson (University of Idaho, USA), quien los usaba para explicar el ajuste de modelos estadísticos. El Dr Christian Salas-Eljatib fue un estudiante de postgrado en estadística del Prof. Robinson en la Univ. of Idaho.

References

Stage AR. 1963. A mathematical approach to polymorphic site index curves for Grand fir. Forest Science 9(2):167–180.

Examples

data(treegr2)    
head(treegr2)

Tree-list data in a forest inventory.

Description

Tree-level variables measured within three sample plots in a forest inventory. Notice that plots might have different areas.

Usage

data(treelistinve)

Format

Contains tree-level variables, as follows:

plot

Plot number.

plot.size

Plot size, in m2^{2}.

tree

Tree identificator

species

species common name as follows: Olivillo= Aextocicon puncatatum, Tepa= Laureliopsis philippiana, Lingue= Persea lingues, Coigue=Nothofagus dombeyi, Roble=Nothofagus obliqua, Other=Other

dbh

Diameter at breast-height, in cm

toth

Total height, in m. Only measured for some sample trees.

Source

The data are provided courtesy of Prof. Christian Salas-Eljatib (Universidad de Chile, Santiago, Chile).

References

- Salas C. 2001. Caracterización básica del relicto de Biodiversidad Rucamanque. Bosque Nativo, 29:3-9. https://eljatib.com/publication/2001-06-01_caracterizacion_basi/

- Salas C. 2002. Ajuste y validación de ecuaciones de volumen para un relicto del bosque de Roble-Laurel-Lingue. Bosque 23(2): 81-92. doi:10.4067/S0717-92002002000200009 https://eljatib.com/publication/2002-07-01_ajuste_y_validacion_/

Examples

data(treelistinve)    
head(treelistinve) 
tapply(treelistinve$dbh,treelistinve$species,summary)

Lista de árboles en un inventario forestal.

Description

Variables a nivel de árbol medidas en tres unidades de muestreo establecidas en un inventario forestal. Note que las parcelas pueden tener diferentes superficies. Las parcelas fueron establecidas en un bosque secundario dominando por Nothofagus obliqua en las cercanias de Temuco.

Usage

data(treelistinve2)

Format

Contiene variables a nivel de árbol dentro de parcelas.

parce

Número de la parcela de muestreo.

sup.parce

Superficie de la parcela, en m2^{2}.

arbol

Número identificador del árbol.

spp

Nombre comun de especies como sigue: Olivillo= Aextocicon puncatatum, Tepa= Laureliopsis philippiana, Lingue= Persea lingue, Coigue=Nothofagus dombeyi, Roble=Nothofagus obliqua, Other=Other

dap

Diámetro a la altura del pecho, en cm.

atot

Altura total, en m. Solo medida en algunas árboles muestra.

Source

Los datos fueron cedidos por el Prof. Christian Salas-Eljatib, Universidad de Chile (Santiago, Chile).

References

- Salas C. 2001. Caracterización básica del relicto de Biodiversidad Rucamanque. Bosque Nativo, 29:3-9. https://eljatib.com/publication/2001-06-01_caracterizacion_basi/

- Salas C. 2002. Ajuste y validación de ecuaciones de volumen para un relicto del bosque de Roble-Laurel-Lingue. Bosque 23(2): 81-92. doi:10.4067/S0717-92002002000200009 https://eljatib.com/publication/2002-07-01_ajuste_y_validacion_/

Examples

data(treelistinve2)    
unique(treelistinve2$parce) 
table(treelistinve2$parce,treelistinve2$sup.parce)
tapply(treelistinve2$dap,treelistinve2$spp,summary)

Diameter, height and volume for Black Cherry Trees

Description

This data set provides measurements of the diameter, height and volume of timber in 31 felled black cherry trees. The records are a slight modification to the original dataframe "trees" from the datasets R package.

Usage

data(treevol)

Format

A data frame with 31 observations and three variables

dbh

Diameter at breast height, in cm.

toth

Total height, in m.

vtot

Timber volume, in cubic meters.

Source

Ryan TA, Joiner BL, and Ryan BF. 1976. The Minitab Student Handbook. Duxbury Press.

Examples

pairs(treevol, panel = panel.smooth, main = "treevol dataframe")
plot(vtot ~ dbh, data = treevol, log = "xy")
coplot(log(vtot) ~ log(dbh) | toth, data = treevol,
       panel = panel.smooth)
summary(m1 <- lm(log(vtot) ~ log(dbh), data = treevol))
summary(m2 <- update(m1, ~ . + log(toth), data = treevol))
anova(m1,m2)

Volumen, altura, y diámetro para árboles de Black Cherry

Description

Estos datos provienen de mediciones de volumen, altura y diámetro en 31 árboles volteados de black cherry (Prunus serotina). Son una modificacion la dataframe 'trees' del paquete datasets de R.

Usage

data(treevol2)

Format

Datos con 31 observaciones y tres variables

dap

diámetro a la altura del pecho, en cm

atot

altural total, en m

vtot

volumen total, en m3^{3}

Source

Ryan, T. A., Joiner, B. L. and Ryan, B. F. (1976) The Minitab Student Handbook. Duxbury Press.

Examples

pairs(treevol2, panel = panel.smooth, main = "treevol dataframe")
plot(vtot ~ dap, data = treevol2, log = "xy")
coplot(log(vtot) ~ log(dap) | atot, data = treevol2,
       panel = panel.smooth)
summary(m1 <- lm(log(vtot) ~ log(dap), data = treevol2))
summary(m2 <- update(m1, ~ . + log(atot), data = treevol2))
anova(m1,m2)

Tree volume of roble (Nothofagus obliqua) in the Rucamanque forest

Description

These are tree-level measurement data of sample trees in the Rucamanque experimental forest, near Temuco, in the Araucania region in south-centralChile, measured in 1999. The data are the same as in the dataframe "treevolruca", but only having observations for the species roble (Nothofagus obliqua).

Usage

data(treevolroble)

Format

Contains tree-level variables, as follows:

tree.no

Tree id

dbh

Diameter at breast height, in cm

toth

Total height, in m.

d6

Upper-stem diameter at 6 m, in cm

totv

Tree gross volume, in m3^{3} with bark.

Source

The data are provided courtesy of Dr Christian Salas at the Universidad de Chile (Santiago, Chile).

References

- Salas C. 2002. Ajuste y validación de ecuaciones de volumen para un relicto del bosque de Roble-Laurel-Lingue. Bosque 23(2): 81-92. doi:10.4067/S0717-92002002000200009 https://eljatib.com/publication/2002-07-01_ajuste_y_validacion_/

Examples

data(treevolroble)    
head(treevolroble)

Volumen a nivel de árbol para roble (Nothofagus obliqua) especie en el bosque de Rucamanque

Description

Volumen, altura y diámetro, entre otras para árboles muestra de roble (Nothofagus obliqua) en el bosque de Rucamanque, cerca de Temuco, en la región de la Araucania, en el sur de Chile.

Usage

data(treevolroble2)

Format

Las siguientes columnas son parte de la dataframe:

arbol

Número del árbol.

especie

Especie.

dap

Diámetro a la altura del pecho, en cm.

atot

Altura total, en m.

d6

Diámetro fustal a los 6 m, en cm.

vtot

Volumen bruto total, en m3^{3} with bark.

Source

Los datos son proporcionados por el Prof. Christian Salas (Universidad de Chile).

References

- Salas C. 2002. Ajuste y validación de ecuaciones de volumen para un relicto del bosque de Roble-Laurel-Lingue. Bosque 23(2): 81-92. doi:10.4067/S0717-92002002000200009 https://eljatib.com/publication/2002-07-01_ajuste_y_validacion_/

Examples

data(treevolroble2)    
head(treevolroble2)

Tree volume by species in the Rucamanque forest

Description

These are tree-level measurement data of sample trees in the Rucamanque experimental forest, near Temuco, in the Araucania region in south-centralChile, measured in 1999. The following species are part of the data: laurel (laurelia sempervirens), lingue (Persea lingue), olivillo (Aextocicon puncatum), roble (Nothofagus obliqua), tepa (Laureliosis philippiana), y tineo (Weinmannia trichosperma).

Usage

data(treevolruca)

Format

Contains tree-level variables, as follows:

tree.no

Tree id.

spp

Species.

dbh

Diameter at breast height, in cm.

toth

Total height, in m.

d6

Upper-stem diameter at 6 m, in cm.

totv

Tree gross volume, in m3^{3} with bark.

Source

The data were provided courtesy of Dr Christian Salas (Universidad de Chile, Santiago, Chile).

References

- Salas C. 2002. Ajuste y validación de ecuaciones de volumen para un relicto del bosque de Roble-Laurel-Lingue. Bosque 23(2): 81-92. doi:10.4067/S0717-92002002000200009 https://eljatib.com/publication/2002-07-01_ajuste_y_validacion_/

Examples

data(treevolruca)    
head(treevolruca)

Volumen a nivel de árbol en el bosque de Rucamanque

Description

Volumen, altura y diámetro, entre otras para árboles muestra en el bosque de Rucamanque, cerca de Temuco, en la region de la Araucanía, en el sur de Chile. Las siguientes especies son parte de los datos: laurel (laurelia sempervirens), lingue (Persea lingue), olivillo (Aextocicon puncatum), roble (Nothofagus obliqua), tepa (Laureliosis philippiana), y tineo (Weinmannia trichosperma).

Usage

data(treevolruca2)

Format

Las siguientes columnas son parte de la dataframe:

arbol

Número del árbol.

especie

Especie.

dap

Diámetro a la altura del pecho, en cm.

atot

Altura total, en m.

d6

Diámetro fustal a los 6 m, en cm.

vtot

Volumen bruto total, en m3^{3} with bark.

Source

Los datos fueron cedidos por el Dr Christian Salas-Eljatib (Chile).

References

- Salas C. 2002. Ajuste y validación de ecuaciones de volumen para un relicto del bosque de Roble-Laurel-Lingue. Bosque 23(2): 81-92. doi:10.4067/S0717-92002002000200009 https://eljatib.com/publication/2002-07-01_ajuste_y_validacion_/

Examples

data(treevolruca2)    
head(treevolruca2)

Creates a scatterplot with superposing boxplots

Description

The function creates a scatterplot with superposing boxplots for the Y-axis variable. To a simple scatterplot between the response variable 'y' and the predictor variable 'x', this function superposes boxplots of the response by groups of the predictor variable. The main aim of the above described graph is to get a sense of the distribution of the response variable depending upon the predictor variable.

Usage

xyboxplot(x = x, y = y, col.dots = "blue", xlab = NULL, ylab = NULL)

Arguments

x

A numeric vector representing the time variable (X-axis).

y

A numeric vector representing the response variable (Y-axis).

col.dots

(optional) A string specifying the dot colors. Default is "blue".

xlab

(optional) A string specifying X-axis label.

ylab

(optional) A string specifying Y-axis label.

Details

Notice that the superposing boxplots for the Y-axis variable are computed by grouping the X-axis variable in 10 classes. Those classes are set by computing the ten percentiles of the X-axis variable, therefore each group has the same number of observations.

Value

The function returns the above described graph.

Author(s)

Christian Salas-Eljatib

References

- Salas-Eljatib C. 2021. Análisis de datos con el programa estadístico R: una introducción aplicada. Ediciones Universidad Mayor. Santiago, Chile. https://eljatib.com

- Salas C, Stage AR, and Robinson AP. 2008. Modeling effects of overstory density and competing vegetation on tree height growth. Forest Science 54(1):107-122. doi:10.1093/forestscience/54.1.107

Examples

data(fishgrowth)
df <- fishgrowth
xyboxplot(x=df$age,y=df$length)
xyboxplot(x=df$age,y=df$length)

A scatterplot with marginal histograms

Description

The function produces a scatterplot between the 'y'-axis variable and the 'x'-axis variable, but also adding the marginal histograms for both variables.

Usage

xyhist(
  x = x,
  y = y,
  col.x = "blue",
  col.y = "red",
  xlab = NULL,
  ylab = NULL,
  x.lim = NULL,
  y.lim = NULL
)

Arguments

x

A numeric vector representing the X-axis variable

y

A numeric vector representing the Y-axis variable

col.x

(optional) A string specifying the color of the histogram of the X-variable. Default is "blue".

col.y

(optional) A string specifying the color of the histogram of the Y-variable. Default is "red".

xlab

(optional) A string specifying X-axis label. Default is "xvar".

ylab

(optional) A string specifying Y-axis label. Default is "yvar".

x.lim

(optional) A vector of two elements with the limits of the Y-axis. Default is the range of the X-variable.

y.lim

(optional) A vector of two elements with the limits of the Y-axis. Default is the range of the Y-variable.

Details

Both the response variable (Y-axis) and the predictor variable (X-axis) must be numeric.

Value

The function returns the above described graph.

Author(s)

Christian Salas-Eljatib

References

- Salas-Eljatib C. 2021. Análisis de datos con el programa estadístico R: una introducción aplicada. Ediciones Universidad Mayor. Santiago, Chile. https://eljatib.com

Examples

data(treevolroble)
df <- treevolroble
head(df)
xyhist(x=df$dbh,y=df$toth) 
xyhist(x=df$dbh,y=df$toth, xlab="Variable X",  ylab="Variable Y") 
xyhist(x=df$dbh,y=df$toth, xlab="Variable X", ylab="Variable Y", 
  col.x = "gray",col.y="white")

Figure of a matrix of scatterplots and histograms for several variables.

Description

The function produces a panel of multiple scatterplots and histograms, showing the correlation coefficient among all pairs of variables. Notice that the data must contain only numeric variables.

Usage

xymultiplot(
  x,
  smooth = TRUE,
  scale = FALSE,
  density = TRUE,
  digits = 2,
  method = "pearson",
  pch = 20,
  lm = FALSE,
  cor = TRUE,
  jiggle = FALSE,
  factor = 2,
  col.hist = "cyan",
  col.densi.curve = "black",
  show.points = TRUE,
  col.points = "gray",
  smoother = FALSE,
  col.smooth = "red",
  ellipses = FALSE,
  col.ellip = "blue",
  col.cent.point = "green",
  rug = TRUE,
  breaks = "Sturges",
  cex.cor = 1,
  ci = FALSE,
  alpha = 0.05,
  ...
)

Arguments

x

is a dataframe containing all the numeric variables to be used for drawing the panel plot

smooth

a logical value for drawing smooth curves. The default is set to TRUE.

scale

scales the correlation font by the size of the absolute correlation. The default is set to FALSE.

density

a logical value for drawing a density curve. The default is set to TRUE.

digits

an optional numeric value for the digits to be used for drawing the correlation coefficient in the panel. Defaults is set to 2.

method

a string giving the method to be used for computing the correlation coefficient. Default is set to "pearson".

pch

The plot character (The default is 20, which looks like '.').

lm

Plot the linear fit rather than the LOESS smoothed fits. The default is FALSE.

cor

If plotting regressions, should correlations be reported? The default is TRUE.

jiggle

Should the points be jittered before plotting? The default is FALSE.

factor

factor for jittering (1-5), therefore only needed if "jiggle" is set to TRUE.

col.hist

a string giving the color to be used for the histograms of the panel. Default is set to "cyan".

col.densi.curve

a string with the name of the color to be used for the density curve. The default is set to "black".

show.points

a logical value for drawing the points in the scatter-plots. Defauls is set to TRUE.

col.points

a string giving the color to be used for the data points. Default is set to "gray".

smoother

If TRUE, then smooth.scatter the data points – slow but pretty with lots of subjects

col.smooth

a string giving the color to be used for the smoothed curve of the scatterplot. Default is set to "red".

ellipses

an optional logical value for drawing an ellipse for the scatter-plots. The default is set to FALSE.

col.ellip

a string giving the color to be used for the ellipse of the scatterplot. The default is set to "blue".

col.cent.point

a string giving the color to be used for the centroid point of the ellipse of the scatterplot. The default is set to "blue".

rug

a logical value for drawing the rugs in the histograms. Defauls is set to TRUE.

breaks

a string giving the method to be used for obtaining the breaks of the histogram. Defauls is set to "Sturges".

cex.cor

If this is specified, this will change the size of the text in the correlations. this allows one to also change the size of the points in the plot by specifying the normal cex values. If just specifying cex, it will change the character size, if cex.cor is specified, then cex will function to change the point size.

ci

Draw confidence intervals for the linear model or for the loess fit, defaults to ci=FALSE. If confidence intervals are not drawn, the fitting function is lowess.

alpha

an optional numeric value for the significance level. Defauls is set to 0.05.

...

other graphical parameters (see par and section ‘Details’ below).

Details

Generates a multipanel (matrix) of scatterplots and histograms to explore potential relationships among variables.

Value

This function returns a multipanel of scatterplots and histograms

Author(s)

A modification of Christian Salas-Eljatib of the function pairs.panels of the package "psych".

References

- Salas-Eljatib C. 2021. Análisis de datos con el programa estadístico R: una introducción aplicada. Ediciones Universidad Mayor. Santiago, Chile. https://eljatib.com

Examples

##First example
data(bears2)
head(bears2)
df <- bears2[,c('peso','edad','cabezaL','cabezaA','largo','pechoP')]
descstat(df)
xymultiplot(df)
xymultiplot(df,ellipse=TRUE)
xymultiplot(df,ellipses=TRUE,col.cent.point = "yellow",
 col.densi.curve = "dark green",col.hist = "white")