Title: | Calculate Quantitative Ethnobotany Indices |
---|---|
Description: | An implementation of the quantitative ethnobotany indices in R. The goal is to provide an easy-to-use platform for ethnobotanists to assess the cultural significance of plant species based on informant consensus. The package closely follows the paper by Tardio and Pardo-de-Santayana (2008). Tardio, J., and M. Pardo-de-Santayana, 2008. Cultural Importance Indices: A Comparative Analysis Based on the Useful Wild Plants of Southern Cantabria (Northern Spain) 1. Economic Botany, 62(1), 24-39. <doi:10.1007/s12231-007-9004-5>. |
Authors: | Cory Whitney [aut, cre] |
Maintainer: | Cory Whitney <[email protected]> |
License: | GPL |
Version: | 0.1.9 |
Built: | 2024-11-19 04:10:32 UTC |
Source: | https://github.com/cwwhitney/ethnobotanyr |
Calculates the Cultural Importance Index (CI) per species.
CIs(data)
CIs(data)
data |
is an ethnobotany data set with column 1 'informant' and 2 'sp_name' as row identifiers of informants and of species names respectively. The rest of the columns are the identified ethnobotany use categories. The data should be populated with counts of uses per informant (should be 0 or 1 values). |
Data frame of species and Cultural Importance Index (CI) values.
Identification for informants and species must be listed by the names 'informant' and 'sp_name' respectively in the data set. The rest of the columns should all represent separate identified ethnobotany use categories. These data should be populated with counts of uses per informant (should be 0 or 1 values).
Tardio, Javier, and Manuel Pardo-de-Santayana. 2008. “Cultural Importance Indices: A Comparative Analysis Based on the Useful Wild Plants of Southern Cantabria (Northern Spain) 1.” Economic Botany 62 (1): 24–39.
Whitney, C. W., Bahati, J., and Gebauer, J. (2018), Ethnobotany and agrobiodiversity; valuation of plants in the homegardens of southwestern Uganda. Ethnobiology Letters, 9(2), 90-100. doi:10.14237/ebl.9.2.2018.503
#Use built-in ethnobotany data example CIs(ethnobotanydata) #Generate random dataset of three informants uses for four species eb_data <- data.frame(replicate(10,sample(0:1,20,rep=TRUE))) names(eb_data) <- gsub(x = names(eb_data), pattern = "X", replacement = "Use_") eb_data$informant <- sample(c('User_1', 'User_2', 'User_3'), 20, replace=TRUE) eb_data$sp_name <- sample(c('sp_1', 'sp_2', 'sp_3', 'sp_4'), 20, replace=TRUE) CIs(eb_data)
#Use built-in ethnobotany data example CIs(ethnobotanydata) #Generate random dataset of three informants uses for four species eb_data <- data.frame(replicate(10,sample(0:1,20,rep=TRUE))) names(eb_data) <- gsub(x = names(eb_data), pattern = "X", replacement = "Use_") eb_data$informant <- sample(c('User_1', 'User_2', 'User_3'), 20, replace=TRUE) eb_data$sp_name <- sample(c('sp_1', 'sp_2', 'sp_3', 'sp_4'), 20, replace=TRUE) CIs(eb_data)
Calculates the Cultural Value (CVe) per ethnospecies.
CVe(data)
CVe(data)
data |
is an ethnobotany data set with column 1 'informant' and 2 'sp_name' as row identifiers of informants and of ethnospecies names respectively. |
Data frame of ethnospecies and Cultural Value (CVe) values.
Identification for informants and ethnospecies must be listed by the names 'informant' and 'sp_name' respectively in the data set. The rest of the columns should all represent separate identified ethnobotany use categories. These data should be populated with counts of uses per informant (should be 0 or 1 values).
Reyes-Garcia, V., T. Huanca, V. Vadez, and W. Leonard. 2006. “Cultural, Practical, and Economic Value of Wild Plants: A Quantitative Study in the Bolivian Amazon.” Economic Botany.
#Use built-in ethnobotany data example CVe(ethnobotanydata) #Generate random dataset of three informants uses for four species eb_data <- data.frame(replicate(10,sample(0:1,20,rep=TRUE))) names(eb_data) <- gsub(x = names(eb_data), pattern = "X", replacement = "Use_") eb_data$informant <- sample(c('User_1', 'User_2', 'User_3'), 20, replace=TRUE) eb_data$sp_name <- sample(c('sp_1', 'sp_2', 'sp_3', 'sp_4'), 20, replace=TRUE) CVe(eb_data)
#Use built-in ethnobotany data example CVe(ethnobotanydata) #Generate random dataset of three informants uses for four species eb_data <- data.frame(replicate(10,sample(0:1,20,rep=TRUE))) names(eb_data) <- gsub(x = names(eb_data), pattern = "X", replacement = "Use_") eb_data$informant <- sample(c('User_1', 'User_2', 'User_3'), 20, replace=TRUE) eb_data$sp_name <- sample(c('sp_1', 'sp_2', 'sp_3', 'sp_4'), 20, replace=TRUE) CVe(eb_data)
Creates a simple alluvial plot of species and uses for ethnobotany studies.
ethno_alluvial(data, alpha = 0, colors = NULL)
ethno_alluvial(data, alpha = 0, colors = NULL)
data |
is an ethnobotany data set with column 1 'informant' and 2 'sp_name' as row identifiers of informants and of species names respectively. The rest of the columns are the identified ethnobotany use categories. The data should be populated with counts of uses per person (should be 0 or 1 values). |
alpha |
is a number between 0 and 1 for the level of transparency behind the labels on the strata (default is 0). |
colors |
is the color palette to be used for the fill of the bars. The default is from the rainbow palette with the number of plants in the data |
Alluvial diagram showing all use reports for each use (center) related to each species (left) and informant (right) in the data set.
Identification for informants and species must be listed by the names 'informant' and 'sp_name' respectively in the data set. The rest of the columns represent the identified ethnobotany use categories. These data should be populated with counts of uses per person (should be 0 or 1 values).
Mon, Aye Mya, Yinxian Shi, Xuefei Yang, Pyae Phyo Hein, Thaung Naing Oo, Cory Whitney, and Yongping Yang. “The Uses of Fig (Ficus) by Five Ethnic Minority Communities in Southern Shan State, Myanmar.” Journal of Ethnobiology and Ethnomedicine 16, no. 5 (2020). doi:10.1186/s13002-020-00406-z
#Use built-in ethnobotany data example ethno_alluvial(ethnobotanydata) #Generate random dataset of three informants uses for four species eb_data <- data.frame(replicate(10,sample(0:1,20,rep=TRUE))) names(eb_data) <- gsub(x = names(eb_data), pattern = "X", replacement = "Use_") eb_data$informant <- sample(c('User_1', 'User_2', 'User_3'), 20, replace=TRUE) eb_data$sp_name <- sample(c('sp_1', 'sp_2', 'sp_3', 'sp_4'), 20, replace=TRUE) # Default plot #### ethno_alluvial(eb_data)
#Use built-in ethnobotany data example ethno_alluvial(ethnobotanydata) #Generate random dataset of three informants uses for four species eb_data <- data.frame(replicate(10,sample(0:1,20,rep=TRUE))) names(eb_data) <- gsub(x = names(eb_data), pattern = "X", replacement = "Use_") eb_data$informant <- sample(c('User_1', 'User_2', 'User_3'), 20, replace=TRUE) eb_data$sp_name <- sample(c('sp_1', 'sp_2', 'sp_3', 'sp_4'), 20, replace=TRUE) # Default plot #### ethno_alluvial(eb_data)
Determine the probability that informant citations for a given use are 'correct' given informant responses to the use category for each plant, an estimate of each person's prior_for_answers with this plant and use, and the number of possible answers about this plant use.
ethno_bayes_consensus(data, answers = 2, prior_for_answers, prior = -1)
ethno_bayes_consensus(data, answers = 2, prior_for_answers, prior = -1)
data |
is an ethnobotany data set with column 1 'informant' and 2 'sp_name' as row identifiers of informants and of species names respectively. The rest of the columns are the identified ethnobotany use categories. The data should be populated with counts of uses per person (should be 0 or 1 values). |
answers |
The number of answers available for each question. These are set to '2' because the way the package works at the moment users can have either a '1' or a '0' in the table. It is however, possible to have more. |
prior_for_answers |
A matrix representing the probability of a given use being more likely. If not provided the function assumes a uniform distribution across uses. |
prior |
a prior distribution of probabilities over all answers as a matrix. If this is not provided the function assumes a uniform distribution (prior = -1). |
A matrix, where columns represent plant use categories and rows represent responses per person and plant (matching the data). Each value represents the bayes_consensus that an answer was 'correct' for a particular use, within the cultural consensus framework.
Identification for informants and species must be listed by the names 'informant' and 'sp_name' respectively in the data set. The rest of the columns should all represent separate identified ethnobotany use categories. These data should be populated with counts of uses per informant (should be 0 or 1 values).
ethnobotanyR users often have a large number of counts in cells of the data set after categorization (i.e one user cites ten different ‘food’ uses but this is just one category). Most quantitative ethnobotany tools are not equipped for cases where the theoretical maximum number of use reports in one category, for one species by one informant is >1. This function and the bayes_boot function may be useful to work with these richer datasets for the Bayes consensus analysis.
Oravecz, Z., Vandekerckhove, J., & Batchelder, W. H. (2014). Bayesian Cultural Consensus Theory. Field Methods, 1525822X13520280. doi:10.1177/1525822X13520280
Romney, A. K., Weller, S. C., & Batchelder, W. H. (1986). Culture as Consensus: A Theory of Culture and Informant Accuracy. American Anthropologist, 88(2), 313-338.
Alastair Jamieson Lane and Benjamin Grant Purzycki (2016), AnthroTools: Some custom tools for anthropology.
#Use built-in ethnobotany data example #assign a non-informative prior to prior_for_answers with 'prior_for_answers=0.5' ethno_bayes_consensus(ethnobotanydata, answers = 2, prior_for_answers = 0.5, prior = -1) #Generate random dataset of three informants uses for four species eb_data <- data.frame(replicate(10,sample(0:1,20,rep=TRUE))) names(eb_data) <- gsub(x = names(eb_data), pattern = "X", replacement = "Use_") eb_data$informant <- sample(c('User_1', 'User_2', 'User_3'), 20, replace=TRUE) eb_data$sp_name <- sample(c('sp_1', 'sp_2', 'sp_3', 'sp_4'), 20, replace=TRUE) #assign a non-informative prior to prior_for_answers eb_prior_for_answers <- rep(0.5, len = nrow(eb_data)) ethno_bayes_consensus(eb_data, answers = 5, prior_for_answers = eb_prior_for_answers)
#Use built-in ethnobotany data example #assign a non-informative prior to prior_for_answers with 'prior_for_answers=0.5' ethno_bayes_consensus(ethnobotanydata, answers = 2, prior_for_answers = 0.5, prior = -1) #Generate random dataset of three informants uses for four species eb_data <- data.frame(replicate(10,sample(0:1,20,rep=TRUE))) names(eb_data) <- gsub(x = names(eb_data), pattern = "X", replacement = "Use_") eb_data$informant <- sample(c('User_1', 'User_2', 'User_3'), 20, replace=TRUE) eb_data$sp_name <- sample(c('sp_1', 'sp_2', 'sp_3', 'sp_4'), 20, replace=TRUE) #assign a non-informative prior to prior_for_answers eb_prior_for_answers <- rep(0.5, len = nrow(eb_data)) ethno_bayes_consensus(eb_data, answers = 5, prior_for_answers = eb_prior_for_answers)
Creates a non-parametric bootstrap as a Bayesian Model https://www.sumsar.net/blog/2015/04/the-non-parametric-bootstrap-as-a-bayesian-model/. This is meant to be applied for ethnobotany data and indices in the ethnobotanyR package. Performs a Bayesian bootstrap and returns a sample of size 'n1' representing the posterior distribution of the chosen statistic (i.e. 'mean'). The function returns a vector if the statistic is one-dimensional (like for mean(...)) or a data.frame if the statistic is multi-dimensional (like for the coefficients 'coefs.' of a regression model 'lm').
ethno_boot(data, statistic, n1 = 1000, n2 = 1000, ...)
ethno_boot(data, statistic, n1 = 1000, n2 = 1000, ...)
data |
Can be either a vector, matrix or a data.frame. |
statistic |
A function that accepts data as its first argument. Should return a numeric vector. |
n1 |
The size of the bootstrap sample. |
n2 |
The sample size used to calculate the statistic for each bootstrap draw. |
... |
Further arguments passed on to the statistic function. |
Bayesian bootstrap of chosen ethnobotany indices in ethnobotanyR package.
This function was inspired by Rasmus Bååth's “The Non-Parametric Bootstrap as a Bayesian Model” Publishable Stuff, 2015. https://www.sumsar.net/blog/2015/04/the-non-parametric-bootstrap-as-a-bayesian-model/. In order to understand the various possible applications of this function for ethnobotany analyses it is important to read through that work.
ethnobotanyR users often have a large number of counts in cells of the data set after categorization (i.e one user cites ten different ‘food’ uses but this is just one category). Most quantitative ethnobotany tools are not equipped for cases where the theoretical maximum number of use reports in one category, for one species by one informant is >1. This function and the ethno_bayes_consensus function may be useful to work with these richer datasets for the Bayes consensus analysis.
Bååth, Rasmus. “The Non-Parametric Bootstrap as a Bayesian Model” Publishable Stuff, 2015. https://www.sumsar.net/blog/2015/04/the-non-parametric-bootstrap-as-a-bayesian-model/. Rubin, Donald B. “The Bayesian Bootstrap.” Annals of Statistics 9, no. 1 (January 1981): 130–34. doi:10.1214/aos/1176345338.
#Use built-in ethnobotany data example ethno_boot(data = ethnobotanydata$Use_1, statistic = mean, n1 = 1000) #Generate random dataset of three informants uses for four species eb_data <- data.frame(replicate(10,sample(0:1,20,rep=TRUE))) names(eb_data) <- gsub(x = names(eb_data), pattern = "X", replacement = "Use_") eb_data$informant<-sample(c('User_1', 'User_2', 'User_3'), 20, replace=TRUE) eb_data$sp_name<-sample(c('sp_1', 'sp_2', 'sp_3', 'sp_4'), 20, replace=TRUE) # Simple Bayesian bootstrap of the mean #### boot_dataUR <- URs(eb_data) ethno_boot(data = boot_dataUR$URs, statistic = mean) # Generate random dataset of three informants with multiple uses for four species eb_multi_use_data <- data.frame(replicate(10,sample(0:10,20,rep=TRUE))) names(eb_multi_use_data) <- gsub(x = names(eb_multi_use_data), pattern = "X", replacement = "Use_") eb_multi_use_data$informant<-sample(c('User_1', 'User_2', 'User_3'), 20, replace=TRUE) eb_multi_use_data$sp_name<-sample(c('sp_1', 'sp_2', 'sp_3', 'sp_4'), 20, replace=TRUE) # Simple Bayesian bootstrap of the mean of Use_1 #### ethno_boot(data = eb_multi_use_data$Use_1, statistic = mean)
#Use built-in ethnobotany data example ethno_boot(data = ethnobotanydata$Use_1, statistic = mean, n1 = 1000) #Generate random dataset of three informants uses for four species eb_data <- data.frame(replicate(10,sample(0:1,20,rep=TRUE))) names(eb_data) <- gsub(x = names(eb_data), pattern = "X", replacement = "Use_") eb_data$informant<-sample(c('User_1', 'User_2', 'User_3'), 20, replace=TRUE) eb_data$sp_name<-sample(c('sp_1', 'sp_2', 'sp_3', 'sp_4'), 20, replace=TRUE) # Simple Bayesian bootstrap of the mean #### boot_dataUR <- URs(eb_data) ethno_boot(data = boot_dataUR$URs, statistic = mean) # Generate random dataset of three informants with multiple uses for four species eb_multi_use_data <- data.frame(replicate(10,sample(0:10,20,rep=TRUE))) names(eb_multi_use_data) <- gsub(x = names(eb_multi_use_data), pattern = "X", replacement = "Use_") eb_multi_use_data$informant<-sample(c('User_1', 'User_2', 'User_3'), 20, replace=TRUE) eb_multi_use_data$sp_name<-sample(c('sp_1', 'sp_2', 'sp_3', 'sp_4'), 20, replace=TRUE) # Simple Bayesian bootstrap of the mean of Use_1 #### ethno_boot(data = eb_multi_use_data$Use_1, statistic = mean)
An ethnobotany dataset from 20 informants, four species and 10 uses column 1 'informant' lists the names or id's of knowledge holders column 2 'sp_name' lists the names or id's of species The other 10 columns are the identified ethnobotany use categories. The data is populated with counts of uses per person (0 and 1 values).
ethnobotanydata
ethnobotanydata
A data frame with 80 rows and 12 variables:
anonymized id's of 20 knowledge holders
id's of four species
one of the categorized uses of species, 0 and 1 values
one of the categorized uses of species, 0 and 1 values
one of the categorized uses of species, 0 and 1 values
one of the categorized uses of species, 0 and 1 values
one of the categorized uses of species, 0 and 1 values
one of the categorized uses of species, 0 and 1 values
one of the categorized uses of species, 0 and 1 values
one of the categorized uses of species, 0 and 1 values
one of the categorized uses of species, 0 and 1 values
one of the categorized uses of species, 0 and 1 values
...
Creates a simple chord diagram of species and uses for ethnobotany studies. For more on the circlize package see Zuguang Gu's 'Circular Visualization in R' https://jokergoo.github.io/circlize_book/book/
ethnoChord(data, by)
ethnoChord(data, by)
data |
is an ethnobotany data set with column 1 'informant' and 2 'sp_name' as row identifiers of informants and of species names respectively. The rest of the columns are the identified ethnobotany use categories. The data should be populated with counts of uses per person (should be 0 or 1 values). |
by |
indicates the variable that should be mapped to the bottom of the chord diagram. This automatically defaults to the column referring to the species (by = "sp_name") |
Chord diagram figure for each use by 'informant' (top half) related to each 'sp_name' (bottom half) in the data set. To change variable names try using the dplyr rename function.
Identification for informants and species must be listed by the names 'informant' and 'sp_name' respectively in the data set. The rest of the columns represent the identified ethnobotany use categories. These data should be populated with counts of uses per person (should be 0 or 1 values).
Gu, Zuguang, Lei Gu, Roland Eils, Matthias Schlesner, and Benedikt Brors. “Circlize Implements and Enhances Circular Visualization in R.” Bioinformatics, 2014, 393.
Whitney, C. W., Bahati, J., and Gebauer, J. (2018), Ethnobotany and agrobiodiversity; valuation of plants in the homegardens of southwestern Uganda. Ethnobiology Letters, 9(2), 90-100. doi:10.14237/ebl.9.2.2018.503
#Use built-in ethnobotany data example ethnoChord(ethnobotanydata, by = "informant") #Generate random dataset of three informants uses for four species eb_data <- data.frame(replicate(10,sample(0:1,20,rep=TRUE))) names(eb_data) <- gsub(x = names(eb_data), pattern = "X", replacement = "Use_") eb_data$informant <- sample(c('User_1', 'User_2', 'User_3'), 20, replace=TRUE) eb_data$sp_name <- sample(c('sp_1', 'sp_2', 'sp_3', 'sp_4'), 20, replace=TRUE) ethnoChord(eb_data, by = "informant")
#Use built-in ethnobotany data example ethnoChord(ethnobotanydata, by = "informant") #Generate random dataset of three informants uses for four species eb_data <- data.frame(replicate(10,sample(0:1,20,rep=TRUE))) names(eb_data) <- gsub(x = names(eb_data), pattern = "X", replacement = "Use_") eb_data$informant <- sample(c('User_1', 'User_2', 'User_3'), 20, replace=TRUE) eb_data$sp_name <- sample(c('sp_1', 'sp_2', 'sp_3', 'sp_4'), 20, replace=TRUE) ethnoChord(eb_data, by = "informant")
Calculates the frequency of citation (FC) per species.
FCs(data)
FCs(data)
data |
is an ethnobotany data set with column 1 'informant' and 2 'sp_name' as row identifiers of informants and of species names respectively. The rest of the columns are the identified ethnobotany use categories. The data should be populated with counts of uses per person (should be 0 or 1 values). |
Data frame of species and frequency of citation (FC) values.
Prance, G. T., W. Balee, B. M. Boom, and R. L. Carneiro. 1987. “Quantitative Ethnobotany and the Case for Conservation in Amazonia.” Conservation Biology 1 (4): 296–310.
#Use built-in ethnobotany data example FCs(ethnobotanydata) #Generate random dataset of three informants uses for four species eb_data <- data.frame(replicate(10,sample(0:1,20,rep=TRUE))) names(eb_data) <- gsub(x = names(eb_data), pattern = "X", replacement = "Use_") eb_data$informant<-sample(c('User_1', 'User_2', 'User_3'), 20, replace=TRUE) eb_data$sp_name<-sample(c('sp_1', 'sp_2', 'sp_3', 'sp_4'), 20, replace=TRUE) FCs(eb_data)
#Use built-in ethnobotany data example FCs(ethnobotanydata) #Generate random dataset of three informants uses for four species eb_data <- data.frame(replicate(10,sample(0:1,20,rep=TRUE))) names(eb_data) <- gsub(x = names(eb_data), pattern = "X", replacement = "Use_") eb_data$informant<-sample(c('User_1', 'User_2', 'User_3'), 20, replace=TRUE) eb_data$sp_name<-sample(c('sp_1', 'sp_2', 'sp_3', 'sp_4'), 20, replace=TRUE) FCs(eb_data)
Calculates the fidelity level (FL) of the various uses of a species, i.e. the ratio between the number of informants who independently cite the use of a species for the same purposes (Ns * 100) and the total number of informants who mentioned the plant for any use (FCs).
FLs(data)
FLs(data)
data |
is an ethnobotany data set with column 1 'informant' and 2 'sp_name' as row identifiers of informants and of species names respectively. The rest of the columns are the identified ethnobotany use categories. The data should be populated with counts of uses per person (should be 0 or 1 values). |
Data frame of species and fidelity level (FL) values.
Identification for informants and species must be listed by the names 'informant' and 'sp_name' respectively in the data set. The rest of the columns should all represent separate identified ethnobotany use categories. These data should be populated with counts of uses per informant (should be 0 or 1 values).
Friedman, J., Z. Yaniv, A. Dafni, and D. Palewitch. 1986. “A Preliminary Classification of the Healing Potential of Medicinal Plants, Based on a Rational Analysis of an Ethnopharmacological Field Survey Among Bedouins in the Negev Desert, Israel.” Journal of Ethnopharmacology 16 (2-3): 275–87.
#Use built-in ethnobotany data example FLs(ethnobotanydata) #returns the primary use category (Primary.use) and the FLs value #Generate random dataset of three informants uses for four species eb_data <- data.frame(replicate(10,sample(0:1,20,rep=TRUE))) names(eb_data) <- gsub(x = names(eb_data), pattern = "X", replacement = "Use_") eb_data$informant <- sample(c('User_1', 'User_2', 'User_3'), 20, replace=TRUE) eb_data$sp_name <- sample(c('sp_1', 'sp_2', 'sp_3', 'sp_4'), 20, replace=TRUE) FLs(eb_data)
#Use built-in ethnobotany data example FLs(ethnobotanydata) #returns the primary use category (Primary.use) and the FLs value #Generate random dataset of three informants uses for four species eb_data <- data.frame(replicate(10,sample(0:1,20,rep=TRUE))) names(eb_data) <- gsub(x = names(eb_data), pattern = "X", replacement = "Use_") eb_data$informant <- sample(c('User_1', 'User_2', 'User_3'), 20, replace=TRUE) eb_data$sp_name <- sample(c('sp_1', 'sp_2', 'sp_3', 'sp_4'), 20, replace=TRUE) FLs(eb_data)
Calculates the number of uses (NU) per species.
NUs(data)
NUs(data)
data |
is an ethnobotany data set with column 1 'informant' and 2 'sp_name' as row identifiers of informants and of species names respectively. The rest of the columns are the identified ethnobotany use categories. The data should be populated with counts of uses per person (should be 0 or 1 values). |
Data frame of species and number of uses (NU) values.
Identification for informants and species must be listed by the names 'informant' and 'sp_name' respectively in the data set. The rest of the columns should all represent separate identified ethnobotany use categories. These data should be populated with counts of uses per informant (should be 0 or 1 values).
Prance, G. T., W. Balee, B. M. Boom, and R. L. Carneiro. 1987. “Quantitative Ethnobotany and the Case for Conservation in Amazonia.” Conservation Biology 1 (4): 296–310.
#Use built-in ethnobotany data example NUs(ethnobotanydata) #Generate random dataset of three informants uses for four species eb_data <- data.frame(replicate(10,sample(0:1,20,rep=TRUE))) names(eb_data) <- gsub(x = names(eb_data), pattern = "X", replacement = "Use_") eb_data$informant<-sample(c('User_1', 'User_2', 'User_3'), 20, replace=TRUE) eb_data$sp_name<-sample(c('sp_1', 'sp_2', 'sp_3', 'sp_4'), 20, replace=TRUE) NUs(eb_data)
#Use built-in ethnobotany data example NUs(ethnobotanydata) #Generate random dataset of three informants uses for four species eb_data <- data.frame(replicate(10,sample(0:1,20,rep=TRUE))) names(eb_data) <- gsub(x = names(eb_data), pattern = "X", replacement = "Use_") eb_data$informant<-sample(c('User_1', 'User_2', 'User_3'), 20, replace=TRUE) eb_data$sp_name<-sample(c('sp_1', 'sp_2', 'sp_3', 'sp_4'), 20, replace=TRUE) NUs(eb_data)
Creates a radial bar plot of ethnobotany indices in ethnobotanyR package using the ggplot2 library https://ggplot2.tidyverse.org/.
Radial_plot(data, analysis, colors = NULL, legend = "none")
Radial_plot(data, analysis, colors = NULL, legend = "none")
data |
is an ethnobotany data set with column 1 'informant' and 2 'sp_name' as row identifiers of informants and of species names respectively. The rest of the columns are the identified ethnobotany use categories. The data should be populated with counts of uses per person (should be 0 or 1 values). |
analysis |
is one of the quantitative ethnobotany functions from ethnobotanyR, i.e. ethnobotanyR::FCs. |
colors |
is the color palette to be used for the fill of the bars. The default is from the rainbow palette with the number of plants |
legend |
is the option for placing a legend in the radial plot (fits ggplot2 'legend.position' argument). The default is "none" |
Radial bar plot of chosen ethnobotany indices in ethnobotanyR package.
Identification for informants and species must be listed by the names 'informant' and 'sp_name' respectively in the data set. The rest of the columns should all represent separate identified ethnobotany use categories. These data should be populated with counts of uses per informant (should be 0 or 1 values).
Wickham, Hadley. “Reshaping Data with the Reshape Package.” Journal of Statistical Software 21, no. 12 (2007): 1–20.
Wickham, Hadley. ggplot2: Elegant Graphics for Data Analysis. Springer, 2016.
#Use built-in ethnobotany data example and Frequency of Citation function FCs() Radial_plot(ethnobotanydata, analysis = FCs) #Generate random dataset of three informants uses for four species eb_data <- data.frame(replicate(10,sample(0:1,20,rep=TRUE))) names(eb_data) <- gsub(x = names(eb_data), pattern = "X", replacement = "Use_") eb_data$informant <- sample(c('User_1', 'User_2', 'User_3'), 20, replace=TRUE) eb_data$sp_name <- sample(c('sp_1', 'sp_2', 'sp_3', 'sp_4'), 20, replace=TRUE) Radial_plot(data = eb_data, analysis = URs, legend = "none")
#Use built-in ethnobotany data example and Frequency of Citation function FCs() Radial_plot(ethnobotanydata, analysis = FCs) #Generate random dataset of three informants uses for four species eb_data <- data.frame(replicate(10,sample(0:1,20,rep=TRUE))) names(eb_data) <- gsub(x = names(eb_data), pattern = "X", replacement = "Use_") eb_data$informant <- sample(c('User_1', 'User_2', 'User_3'), 20, replace=TRUE) eb_data$sp_name <- sample(c('sp_1', 'sp_2', 'sp_3', 'sp_4'), 20, replace=TRUE) Radial_plot(data = eb_data, analysis = URs, legend = "none")
Calculates the relative frequency of citation (RFC) per species published by Pardo-de-Santayana (2003).
RFCs(data)
RFCs(data)
data |
is an ethnobotany data set with column 1 'informant' and 2 'sp_name' as row identifiers of informants and of species names respectively. The rest of the columns are the identified ethnobotany use categories. The data should be populated with counts of uses per person (should be 0 or 1 values). |
Data frame of species and relative frequency of citation (RFC) values.
Identification for informants and species must be listed by the names 'informant' and 'sp_name' respectively in the data set. The rest of the columns should all represent separate identified ethnobotany use categories. These data should be populated with counts of uses per informant (should be 0 or 1 values).
Tardio, Javier, and Manuel Pardo-de-Santayana. 2008. “Cultural Importance Indices: A Comparative Analysis Based on the Useful Wild Plants of Southern Cantabria (Northern Spain) 1.” Economic Botany 62 (1): 24–39.
#Use built-in ethnobotany data example RFCs(ethnobotanydata) #Generate random dataset of three informants uses for four species eb_data <- data.frame(replicate(10,sample(0:1,20,rep=TRUE))) names(eb_data) <- gsub(x = names(eb_data), pattern = "X", replacement = "Use_") eb_data$informant <- sample(c('User_1', 'User_2', 'User_3'), 20, replace=TRUE) eb_data$sp_name <- sample(c('sp_1', 'sp_2', 'sp_3', 'sp_4'), 20, replace=TRUE) RFCs(eb_data)
#Use built-in ethnobotany data example RFCs(ethnobotanydata) #Generate random dataset of three informants uses for four species eb_data <- data.frame(replicate(10,sample(0:1,20,rep=TRUE))) names(eb_data) <- gsub(x = names(eb_data), pattern = "X", replacement = "Use_") eb_data$informant <- sample(c('User_1', 'User_2', 'User_3'), 20, replace=TRUE) eb_data$sp_name <- sample(c('sp_1', 'sp_2', 'sp_3', 'sp_4'), 20, replace=TRUE) RFCs(eb_data)
Calculates the relative importance index (RI) per species, published by Pardo-de-Santayana (2003).
RIs(data)
RIs(data)
data |
is an ethnobotany data set with column 1 'informant' and 2 'sp_name' as row identifiers of informants and of species names respectively. The rest of the columns are the identified ethnobotany use categories. The data should be populated with counts of uses per person (should be 0 or 1 values). |
Data frame of species and relative importance index (RI) values.
Identification for informants and species must be listed by the names 'informant' and 'sp_name' respectively in the data set. The rest of the columns should all represent separate identified ethnobotany use categories. These data should be populated with counts of uses per informant (should be 0 or 1 values).
Tardio, Javier, and Manuel Pardo-de-Santayana. 2008. “Cultural Importance Indices: A Comparative Analysis Based on the Useful Wild Plants of Southern Cantabria (Northern Spain) 1.” Economic Botany 62 (1): 24–39.
#Use built-in ethnobotany data example RIs(ethnobotanydata) #Generate random dataset of three informants uses for four species eb_data <- data.frame(replicate(10,sample(0:1,20,rep=TRUE))) names(eb_data) <- gsub(x = names(eb_data), pattern = "X", replacement = "Use_") eb_data$informant <- sample(c('User_1', 'User_2', 'User_3'), 20, replace=TRUE) eb_data$sp_name <- sample(c('sp_1', 'sp_2', 'sp_3', 'sp_4'), 20, replace=TRUE) RIs(eb_data)
#Use built-in ethnobotany data example RIs(ethnobotanydata) #Generate random dataset of three informants uses for four species eb_data <- data.frame(replicate(10,sample(0:1,20,rep=TRUE))) names(eb_data) <- gsub(x = names(eb_data), pattern = "X", replacement = "Use_") eb_data$informant <- sample(c('User_1', 'User_2', 'User_3'), 20, replace=TRUE) eb_data$sp_name <- sample(c('sp_1', 'sp_2', 'sp_3', 'sp_4'), 20, replace=TRUE) RIs(eb_data)
Calculates the simplified use value (UV) index for each species in the data set (see Albuquerque et al. 2006). This is calculated the same as the CIs function.
simple_UVs(data)
simple_UVs(data)
data |
is an ethnobotany data set with column 1 'informant' and 2 'sp_name' as row identifiers of informants and of species names respectively. The rest of the columns are the identified ethnobotany use categories. The data should be populated with counts of uses per person (should be 0 or 1 values). |
Data frame of species and simplified use value (UV) index values.
Identification for informants and species must be listed by the names 'informant' and 'sp_name' respectively in the data set. The rest of the columns should all represent separate identified ethnobotany use categories. These data should be populated with counts of uses per informant (should be 0 or 1 values).
Albuquerque, Ulysses P., Reinaldo FP Lucena, Julio M.Monteiro, Alissandra TN Florentino, and Cecilia de Fatima CBR Almeida. 2006. “Evaluating Two Quantitative Ethnobotanical Techniques.” Ethnobotany Research and Applications 4: 51–60.
#Use built-in ethnobotany data example simple_UVs(ethnobotanydata) #Generate random dataset of three informants uses for four species eb_data <- data.frame(replicate(10,sample(0:1,20,rep=TRUE))) names(eb_data) <- gsub(x = names(eb_data), pattern = "X", replacement = "Use_") eb_data$informant <- sample(c('User_1', 'User_2', 'User_3'), 20, replace=TRUE) eb_data$sp_name <- sample(c('sp_1', 'sp_2', 'sp_3', 'sp_4'), 20, replace=TRUE) simple_UVs(eb_data)
#Use built-in ethnobotany data example simple_UVs(ethnobotanydata) #Generate random dataset of three informants uses for four species eb_data <- data.frame(replicate(10,sample(0:1,20,rep=TRUE))) names(eb_data) <- gsub(x = names(eb_data), pattern = "X", replacement = "Use_") eb_data$informant <- sample(c('User_1', 'User_2', 'User_3'), 20, replace=TRUE) eb_data$sp_name <- sample(c('sp_1', 'sp_2', 'sp_3', 'sp_4'), 20, replace=TRUE) simple_UVs(eb_data)
Calculates the use reports (UR) per species, a common metric for ethnobotany studies.
URs(data)
URs(data)
data |
is an ethnobotany data set with column 1 'informant' and 2 'sp_name' as row identifiers of informants and of species names respectively. The rest of the columns are the identified ethnobotany use categories. The data should be populated with counts of uses per person (should be 0 or 1 values). |
Data frame of species and use reports (UR) values.
Identification for informants and species must be listed by the names 'informant' and 'sp_name' respectively in the data set. The rest of the columns should all represent separate identified ethnobotany use categories. These data should be populated with counts of uses per informant (should be 0 or 1 values).
Prance, G. T., W. Balee, B. M. Boom, and R. L. Carneiro. 1987. “Quantitative Ethnobotany and the Case for Conservation in Amazonia.” Conservation Biology 1 (4): 296–310.
Whitney, Cory W., J. Gebauer, and M. Anderson. “A Survey of Wild Collection and Cultivation of Indigenous Species in Iceland.” Human Ecology 40, no. 5 (2012): 781–87. doi:10.1007/s10745-012-9517-0
#Use built-in ethnobotany data example URs(ethnobotanydata) #Generate random dataset of three informants uses for four species eb_data <- data.frame(replicate(10, sample(0:1, 20, rep = TRUE))) names(eb_data) <- gsub(x = names(eb_data), pattern = "X", replacement = "Use_") eb_data$informant <- sample(c('User_1', 'User_2', 'User_3'), 20, replace = TRUE) eb_data$sp_name <- sample(c('sp_1', 'sp_2', 'sp_3', 'sp_4'), 20, replace = TRUE) URs(eb_data)
#Use built-in ethnobotany data example URs(ethnobotanydata) #Generate random dataset of three informants uses for four species eb_data <- data.frame(replicate(10, sample(0:1, 20, rep = TRUE))) names(eb_data) <- gsub(x = names(eb_data), pattern = "X", replacement = "Use_") eb_data$informant <- sample(c('User_1', 'User_2', 'User_3'), 20, replace = TRUE) eb_data$sp_name <- sample(c('sp_1', 'sp_2', 'sp_3', 'sp_4'), 20, replace = TRUE) URs(eb_data)
Calculates the sum of all ethnobotany use reports (UR) for all species, a common metric for ethnobotany studies.
URsum(data)
URsum(data)
data |
is an ethnobotany data set with column 1 'informant' and 2 'sp_name' as row identifiers of informants and of species names respectively. The rest of the columns are the identified ethnobotany use categories. The data should be populated with counts of uses per person (should be 0 or 1 values). |
Single value sum of all ethnobotany use reports (UR) for all species in the data.
Identification for informants and species must be listed by the names 'informant' and 'sp_name' respectively in the data set. The rest of the columns should all represent separate identified ethnobotany use categories. These data should be populated with counts of uses per informant (should be 0 or 1 values).
Prance, G. T., W. Balee, B. M. Boom, and R. L. Carneiro. 1987. “Quantitative Ethnobotany and the Case for Conservation in Amazonia.” Conservation Biology 1 (4): 296–310.
#Use built-in ethnobotany data example URsum(ethnobotanydata) #Generate random dataset of three informants uses for four species eb_data <- data.frame(replicate(10,sample(0:1,20,rep=TRUE))) names(eb_data) <- gsub(x = names(eb_data), pattern = "X", replacement = "Use_") eb_data$informant <- sample(c('User_1', 'User_2', 'User_3'), 20, replace=TRUE) eb_data$sp_name <- sample(c('sp_1', 'sp_2', 'sp_3', 'sp_4'), 20, replace=TRUE) URsum(eb_data)
#Use built-in ethnobotany data example URsum(ethnobotanydata) #Generate random dataset of three informants uses for four species eb_data <- data.frame(replicate(10,sample(0:1,20,rep=TRUE))) names(eb_data) <- gsub(x = names(eb_data), pattern = "X", replacement = "Use_") eb_data$informant <- sample(c('User_1', 'User_2', 'User_3'), 20, replace=TRUE) eb_data$sp_name <- sample(c('sp_1', 'sp_2', 'sp_3', 'sp_4'), 20, replace=TRUE) URsum(eb_data)
Calculates the use value (UV) index for each species in the data set (see Tardio and Pardo-de-Santayana 2008). This is calculated the same as the CIs function.
UVs(data)
UVs(data)
data |
is an ethnobotany data set with column 1 'informant' and 2 'sp_name' as row identifiers of informants and of species names respectively. The rest of the columns are the identified ethnobotany use categories. The data should be populated with counts of uses per person (should be 0 or 1 values). |
Data frame of species and use value (UV) index results.
Identification for informants and species must be listed by the names 'informant' and 'sp_name' respectively in the data set. The rest of the columns should all represent separate identified ethnobotany use categories. These data should be populated with counts of uses per informant (should be 0 or 1 values).
Tardio, Javier, and Manuel Pardo-de-Santayana. “Cultural Importance Indices: A Comparative Analysis Based on the Useful Wild Plants of Southern Cantabria (Northern Spain)1.” Economic Botany 62, no. 1 (May 2008): 24–39. doi:10.1007/s12231-007-9004-5
#Use built-in ethnobotany data example UVs(ethnobotanydata) #Generate random dataset of three informants uses for four species eb_data <- data.frame(replicate(10,sample(0:1,20,rep=TRUE))) names(eb_data) <- gsub(x = names(eb_data), pattern = "X", replacement = "Use_") eb_data$informant<-sample(c('User_1', 'User_2', 'User_3'), 20, replace=TRUE) eb_data$sp_name<-sample(c('sp_1', 'sp_2', 'sp_3', 'sp_4'), 20, replace=TRUE) UVs(eb_data)
#Use built-in ethnobotany data example UVs(ethnobotanydata) #Generate random dataset of three informants uses for four species eb_data <- data.frame(replicate(10,sample(0:1,20,rep=TRUE))) names(eb_data) <- gsub(x = names(eb_data), pattern = "X", replacement = "Use_") eb_data$informant<-sample(c('User_1', 'User_2', 'User_3'), 20, replace=TRUE) eb_data$sp_name<-sample(c('sp_1', 'sp_2', 'sp_3', 'sp_4'), 20, replace=TRUE) UVs(eb_data)