-
Notifications
You must be signed in to change notification settings - Fork 3
/
README.Rmd
94 lines (75 loc) · 2.61 KB
/
README.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
90
91
92
93
---
output: github_document
editor_options:
chunk_output_type: console
---
<!-- README.md is generated from README.Rmd. Please edit that file -->
```{r, include = FALSE}
knitr::opts_chunk$set(
collapse = TRUE,
comment = "#>",
fig.path = "man/figures/README-",
out.width = "100%"
)
```
# treenetproc
<!-- badges: start -->
<!-- badges: end -->
The package `treenetproc` cleans, processes and visualises highly resolved time
series of dendrometer data. In two steps, raw dendrometer data is aligned to
regular time intervals and cleaned.
Further, the package offers functions to extract the day of the year of the
start and end of the growing season as well as several characteristics of
shrinkage and expansion phases.
## Installation
You can install the latest stable version of the package from
[GitHub](https://github.com/) with:
``` {r install packge, echo = TRUE, results = "hide", message=FALSE, warning=FALSE}
# install.packages("devtools")
library(devtools)
devtools::install_github("treenet/treenetproc")
```
<br>
## Example
Below you can see a basic example of a processing result.
```{r Fig_1, fig.width = 6, fig.height = 2, fig.retina = 2, echo = FALSE}
library(treenetproc)
data("dendro_data_L1")
data("dendro_data_L2")
example_L1 <- dendro_data_L1 %>%
dplyr::filter(series == "site-1_dendro-1") %>%
dplyr::filter(ts <= "2013-06-01")
example_L2 <- dendro_data_L2 %>%
dplyr::filter(series == "site-1_dendro-1") %>%
dplyr::filter(ts <= "2013-06-01")
layout(matrix(c(1, 2), nrow = 2), heights = c(1, 1),
widths = 1)
par(mar = c(0, 2.1, 0, 1))
plot(data = example_L1, value ~ ts, type = "l", xaxt = "n",
yaxt = "n", ylab = "", las = 1, col = "grey70")
title(ylab = "raw", mgp = c(0.8, 1, 0))
par(mar = c(0, 2.1, 0, 1))
plot(data = example_L2, value ~ ts, type = "n", xaxt = "n",
yaxt = "n", ylab = "", xlab = "")
title(ylab = "processed", mgp = c(0.8, 1, 0))
lines(data = example_L2, value ~ ts, col = "#08519c")
```
<br>
For sample code and a demonstration of an exemplary workflow, see the vignette
'Introduction to treenetproc':
```{r install vignettes, results="hide", message=FALSE, warning=FALSE}
browseVignettes("treenetproc")
```
If you want to access the vignettes you need to build them when installing
the package:
``` {r install package with vignettes, echo = TRUE, results = "hide", message=FALSE, warning=FALSE}
# install.packages("devtools")
library(devtools)
devtools::install_github("treenet/treenetproc", build_vignettes = TRUE)
```
<br>
## Citation
To cite `treenetproc` in a publication use:
```{r citation, echo = TRUE, message=FALSE, warning=FALSE}
citation("treenetproc")
```