-
Notifications
You must be signed in to change notification settings - Fork 11
/
paper.Rmd
89 lines (64 loc) · 2.66 KB
/
paper.Rmd
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
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
---
output: html_document
---
```{r setup, echo=FALSE}
library(ggplot2)
```
```{r cleanup, echo=FALSE}
source("cleanup-function.R")
### Add your script here
```
```{r author_info, echo=FALSE}
first_name <- "Francois"
last_name <- "Michonneau"
institution <- "FLMNH"
address <- "Gainesville, FL 32611 USA"
```
```{r, results='hide', echo=FALSE}
hol_data <- read.csv(file="data_output/occurrence_holothuria.csv")
long_red_sea <- c(30, 50)
lat_red_sea <- c(10, 32)
hol_data_red_sea <- subset(hol_data, (dwc.decimalLatitude > lat_red_sea[1] & dwc.decimalLatitude < lat_red_sea[2]) &
(dwc.decimalLongitude > long_red_sea[1] & dwc.decimalLatitude < long_red_sea[2]))
## replace by an expression that allows you to calculate the number
## of individuals in the data set that occur in the red sea
n_red_sea <- 999
## replace by an expression that allows you to estimate how many records in the
## original data sets are missing their coordinates
n_missing <- 999
## replace by the an expression that allows you to calculate the number
## of species that occur in the red sea
n_species_red_sea <- 999
## replace by an expression that allows you to calculate the total number
## of species in the dataset
n_species <- 999
```
# The sea cucumber fauna from the Red Sea
By `r last_name`, `r first_name`
From `r institution`
> `r address`
---------------------------------------------
We analyzed all the records for the family Holothuriidae found in
[iDigBio](http://portal.idigbio.org) (N = `r nrow(hol_data)`). Among them,
`r n_red_sea` were found to occur in the Red Sea. They represented
`r n_species_red_sea` species or `r round(100 * n_species_red_sea/n_species, 2)` % of
the species included in our dataset. However, `r n_missing` lots were not associated
with any coordinate information.
The figure below shows a map of all these occurrences.
```{r map, echo=FALSE}
world_map <- map_data("world")
ggplot(hol_data_red_sea) + annotation_map(world_map, fill="gray40", colour="gray40") +
geom_point(aes(x=dwc.decimalLongitude, y=dwc.decimalLatitude, color=dwc.specificEpithet),
position=position_jitter(width=0.2, height=0.2)) +
theme(panel.background = element_rect(fill="aliceblue"),
legend.position = "none") +
coord_map(projection = "mercator", orientation=c(90, 160, 0),
xlim=long_red_sea, # limits on longitude
ylim=lat_red_sea) + # limits on latitude
xlab("Longitude") + ylab("Latitude")
```
This figure shows the map for ...
```{r}
## create a map that shows one of the species of your choice, the most sampled species,
## the full distribution of a species, or whatever else you'd like
```