-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathREADME.Rmd
More file actions
50 lines (41 loc) · 2.37 KB
/
README.Rmd
File metadata and controls
50 lines (41 loc) · 2.37 KB
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
---
output: github_document
editor_options:
chunk_output_type: console
---
The `make_data.R` R script that generates the data can be generated by the
following command:
```{r eval = FALSE}
# install.packages("knitr")
knitr::purl("https://raw.githubusercontent.com/viparc/clires_data/master/make_data.Rmd", documentation = 1L)
```
The data set, as a flat rectangular CSV file, can be downloaded from
[here](https://raw.githubusercontent.com/viparc/clires_data/master/data/viparc.csv):
```{r}
# install.packages("readr")
viparc <- readr::read_csv("https://raw.githubusercontent.com/viparc/clires_data/master/data/viparc.csv",
col_types = paste(c("ciillidddllllll", rep("d", 45)), collapse = ""))
```
```{r include = FALSE}
nb_ab <- sum(grepl("_g", names(viparc))) - 1
```
The data frame contains `r nrow(viparc)` weeks of observation (rows) and
`r ncol(viparc)` variables (columns). The variables are
* **farm:** farm ID;
* **flock:** flock ID (in a given farm);
* **week:** week number (in a given flock of a given farm);
* **sampling:** boolean informing whether there is feces sampling during the week (`TRUE`) or not (`FALSE`);
* **completed:** boolean informing whether the flock is done (`TRUE`) or still ongoing (`FALSE`);
* **nb_chicken:** total number of chicken in the farm;
* **nb_chicken_sold:** total number of chicken sold from the farm;
* **chicken_disease_death** number of chicken in the farm that died from disease between the previous and the current weeks;
* **chicken_sudden_death** number of chicken in the farm that suddenly died (from other causes than the disease) between the previous and the current weeks;
* **respiratory, ..., sudden_death:** presence (`TRUE`) / absence (`FALSE`) of 6 clinical signs in the flock;
* **chicken_disease_death**: number of chicken dying from disease between the previous and the current weeks;
* **chicken_sudden_death**: number of chicken suddenly dying (from other cause than disease) between the previous and the current weeks;
* **amoxicillin_g, ..., unknown_g:** mass, in g, of the `r nb_ab` antimicriobial used in the flock.
In addition, there is also information on the antimicrobial class of each
antimicrobial used in the data set. These data can be download from here:
```{r}
ab_classes <- readr::read_csv("https://raw.githubusercontent.com/viparc/clires_data/master/data/antimicrobial_classes.csv", col_types = "cc")
```