View source: R/rescale_species.R
rescale_species | R Documentation |
This function takes in a dataframe of multi-species data and rescales them so that the value in the starting year is the same. This function accounts for species that have no data at the beginning of the period or those that have no data at teh end of the period.
rescale_species(Data, index = 100, max = 10000, min = 1)
Data |
A matrix, the first column, named year, gives the year. Subsequent named columns give the species. Values in the table are the yearly values to be rescaled. |
index |
The index value for the first year, defaults to 100. |
max |
The upper limit allowed for scaled values. Values greater than
this will be set equal to |
min |
The upper limit allowed for scaled values. Values greater than
this will be set equal to |
A matrix. In each row we have the year, the species and the scaled value. There is also an additional column, 'geomean' giving the geometric mean for each year.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.