Description Usage Arguments Value Examples
This function takes bootstrapped communities (created with the 'bootstrap' function') and sequenctially removes occasional species according to increasing abundance and/or occupancy classes and calculates conservation value metrics. m1-> the proportion of all species that is shared between two communities m2-> the proportion of all species that is unique to one of the two communities m3-> the proportion of the species that occur in one of the communities that is unique to that community Each metric will be calulated multiple times for each of the removal classes (1 to 'seq'), according to the number of randomizations in the bootstrapped communities.
1 2 | conservation_value_seq_CI(x_boot, y_boot, seq, removal_rule = 2,
removal_routine = "a")
|
x_boot |
A set of bootstrapped community matrices, with species in columns and samples in rows for each community in the 3rd axis |
y_boot |
A set of bootstrapped community matrices, with species in columns and samples in rows for each community in the 3rd axis |
seq |
The maximum removal class to be removed. The sequence will wil go from zero to this class (inclusive) |
removal_rule |
The removal_rule to be used.If 1, applies the removal routine to x and y. If 2, applies on to y. |
removal_routine |
The removal_routine to be used. If "a", removes by abundance class using the 'occasional_abundance' function. If "o", removes by occupancy class using the 'occasional_occupancy' function. If "b", removes by abundance and then occupancy, using the same occasional class for both. |
A list with $m1, $m2 and $m3 matrices, each with seq rows and 3 columns the mean value for that metric (m), the lower (2.5
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 | data(community_data)
#Select all samples in Evironment 'A'
comm.A<-community_data[which(community_data$environment == "A"),]
# Select only the abundance matrix (columns 1 and 2 contain the 'environment' and 'sample' data)
comm.A <- comm.A[, 3:ncol(comm.A)]
#Select all samples in Evironment 'B'
comm.B<-community_data[which(community_data$environment == "B"),]
# Select only the abundance matrix (columns 1 and 2 contain the 'environment' and 'sample' data)
comm.B <- comm.B[, 3:ncol(comm.B)]
Create 30 bootstrapped communities for each of the two original communities (comm.A and comm.B)
x_boot<-bootstrap(comm.A, 30)
y_boot<-bootstrap(comm.B, 30)
# Sequentially remove abundance classes from both communities and and calculate the conservation metrics with 95% confidence intervals
conservation_value_seq_CI(x.boot, y.boot, 5)
$m1
m 2.5% 97.5%
0 0.9500000 0.9333333 0.9666667
1 0.9255556 0.8666667 0.9666667
2 0.9044444 0.8333333 0.9425000
3 0.8755556 0.8241667 0.9333333
4 0.8444444 0.7908333 0.9000000
5 0.8100000 0.7333333 0.8666667
$m2
m 2.5% 97.5%
0 0.01444444 0.00000000 0.03333333
1 0.03111111 0.00000000 0.07583333
2 0.04000000 0.00000000 0.10000000
3 0.05000000 0.03333333 0.10000000
4 0.07222222 0.03333333 0.10000000
5 0.10222222 0.06666667 0.17583333
$m3
m 2.5% 97.5%
0 0.01494253 0.00000000 0.03448276
1 0.03251536 0.00000000 0.07844828
2 0.04238617 0.00000000 0.10446429
3 0.05403702 0.03448276 0.10823413
4 0.07885902 0.03571429 0.11228632
5 0.11211844 0.07142857 0.19318783
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.