Skip to content

Commit

Permalink
Update filtering vignette
Browse files Browse the repository at this point in the history
  • Loading branch information
wkmor1 committed Feb 29, 2024
1 parent c673eb4 commit 078a43b
Show file tree
Hide file tree
Showing 17 changed files with 60 additions and 93 deletions.
47 changes: 18 additions & 29 deletions docs/articles/v05_filtering.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/pkgdown.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,5 @@ articles:
v03_selecting_variables: v03_selecting_variables.html
v04_metadata: v04_metadata.html
v05_filtering: v05_filtering.html
last_built: 2024-01-25T08:09Z
last_built: 2024-02-29T07:54Z

2 changes: 1 addition & 1 deletion docs/search.json

Large diffs are not rendered by default.

Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
8 changes: 4 additions & 4 deletions inst/vign/v05_filtering.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ See `?filters` section "Location" for more details
The event or import date of records can be used to filter occurrence data from
FinBIF. The date filters can be a single year, month or date,
```{details date-filter}
finbif_occurrence(filter = list(date_range_ym = c("2019-12")))
finbif_occurrence(filter = list(date_range_ym = c("2020-12")))
```
, or for record events, a range as a character vector.
```{details date-range-filter}
Expand Down Expand Up @@ -80,12 +80,12 @@ strict <- c(
record_quality = "expert_verified"
)
permissive <- list(
quality_issues = "both",
record_reliability = c("reliable", "unassessed", "unreliable"),
wild_status = c("wild", "non_wild", "wild_unknown"),
record_quality = c(
"expert_verified", "community_verified", "unassessed", "uncertain",
"erroneous"
)
),
abundance_min = 0
)
c(
strict = finbif_occurrence(filter = strict, count_only = TRUE),
Expand Down
47 changes: 18 additions & 29 deletions inst/vign/v05_filtering.md
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ The event or import date of records can be used to filter occurrence data from
FinBIF. The date filters can be a single year, month or date,

```r
finbif_occurrence(filter = list(date_range_ym = c("2019-12")))
finbif_occurrence(filter = list(date_range_ym = c("2020-12")))
```


Expand All @@ -81,30 +81,19 @@ finbif_occurrence(filter = list(date_range_ym = c("2019-12")))
```r

#> Records downloaded: 10
#> Records available: 20150
#> Records available: 23847
#> A data.frame [10 x 12]
#> record_id scientific_name abundance lat_wgs84 lon_wgs84
#> 1 …KE.921/LGE.627772/1470480 Pteromys volans (Li… NA 61.81362 25.75756
#> 2 …JX.1054648#107 Pica pica (Linnaeus… 3 65.30543 25.70355
#> 3 …JX.1054648#85 Poecile montanus (C… 1 65.30543 25.70355
#> 4 …JX.1054648#103 Garrulus glandarius… 3 65.30543 25.70355
#> 5 …JX.1054648#123 Passer montanus (Li… 3 65.30543 25.70355
#> 6 …JX.1054648#149 Pyrrhula pyrrhula (… 1 65.30543 25.70355
#> 7 …JX.1054648#93 Cyanistes caeruleus… 9 65.30543 25.70355
#> 8 …JX.1054648#95 Parus major Linnaeu… 35 65.30543 25.70355
#> 9 …JX.1054648#137 Carduelis flammea (… 2 65.30543 25.70355
#> 10 …JX.1056695#107 Pica pica (Linnaeus… 6 62.7154 23.0893
#> date_time
#> 1 2019-12-31 12:00:00
#> 2 2019-12-31 10:20:00
#> 3 2019-12-31 10:20:00
#> 4 2019-12-31 10:20:00
#> 5 2019-12-31 10:20:00
#> 6 2019-12-31 10:20:00
#> 7 2019-12-31 10:20:00
#> 8 2019-12-31 10:20:00
#> 9 2019-12-31 10:20:00
#> 10 2019-12-31 10:15:00
#> record_id scientific_name abundance lat_wgs84 lon_wgs84 date_time
#> 1 …107 Pica pica (Linnaeus… 31 65.0027 25.49381 2020-12-31 10:20:00
#> 2 …45 Larus argentatus Po… 1 65.0027 25.49381 2020-12-31 10:20:00
#> 3 …153 Emberiza citrinella… 2 65.0027 25.49381 2020-12-31 10:20:00
#> 4 …49 Columba livia domes… 33 65.0027 25.49381 2020-12-31 10:20:00
#> 5 …117 Corvus corax Linnae… 1 65.0027 25.49381 2020-12-31 10:20:00
#> 6 …111 Corvus monedula Lin… 7 65.0027 25.49381 2020-12-31 10:20:00
#> 7 …161 Sciurus vulgaris Li… 1 65.0027 25.49381 2020-12-31 10:20:00
#> 8 …123 Passer montanus (Li… 28 65.0027 25.49381 2020-12-31 10:20:00
#> 9 …149 Pyrrhula pyrrhula (… 1 65.0027 25.49381 2020-12-31 10:20:00
#> 10 …77 Turdus pilaris Linn… 1 65.0027 25.49381 2020-12-31 10:20:00
#> ...with 0 more record and 6 more variables:
#> coordinates_uncertainty, any_issues, requires_verification, requires_identification,
#> record_reliability, record_quality
Expand Down Expand Up @@ -212,19 +201,19 @@ strict <- c(
record_quality = "expert_verified"
)
permissive <- list(
quality_issues = "both",
record_reliability = c("reliable", "unassessed", "unreliable"),
wild_status = c("wild", "non_wild", "wild_unknown"),
record_quality = c(
"expert_verified", "community_verified", "unassessed", "uncertain",
"erroneous"
)
),
abundance_min = 0
)
c(
strict = finbif_occurrence(filter = strict, count_only = TRUE),
permissive = finbif_occurrence(filter = permissive, count_only = TRUE)
)
#> Error: 1 error occurred:
#> - Invalid name in record reliability: unassessed
#> strict permissive
#> 52654 51733557
```

## Collection
Expand Down
47 changes: 18 additions & 29 deletions vignettes/v05_filtering.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ The event or import date of records can be used to filter occurrence data from
FinBIF. The date filters can be a single year, month or date,

```r
finbif_occurrence(filter = list(date_range_ym = c("2019-12")))
finbif_occurrence(filter = list(date_range_ym = c("2020-12")))
```


Expand All @@ -81,30 +81,19 @@ finbif_occurrence(filter = list(date_range_ym = c("2019-12")))
```r

#> Records downloaded: 10
#> Records available: 20150
#> Records available: 23847
#> A data.frame [10 x 12]
#> record_id scientific_name abundance lat_wgs84 lon_wgs84
#> 1 …KE.921/LGE.627772/1470480 Pteromys volans (Li… NA 61.81362 25.75756
#> 2 …JX.1054648#107 Pica pica (Linnaeus… 3 65.30543 25.70355
#> 3 …JX.1054648#85 Poecile montanus (C… 1 65.30543 25.70355
#> 4 …JX.1054648#103 Garrulus glandarius… 3 65.30543 25.70355
#> 5 …JX.1054648#123 Passer montanus (Li… 3 65.30543 25.70355
#> 6 …JX.1054648#149 Pyrrhula pyrrhula (… 1 65.30543 25.70355
#> 7 …JX.1054648#93 Cyanistes caeruleus… 9 65.30543 25.70355
#> 8 …JX.1054648#95 Parus major Linnaeu… 35 65.30543 25.70355
#> 9 …JX.1054648#137 Carduelis flammea (… 2 65.30543 25.70355
#> 10 …JX.1056695#107 Pica pica (Linnaeus… 6 62.7154 23.0893
#> date_time
#> 1 2019-12-31 12:00:00
#> 2 2019-12-31 10:20:00
#> 3 2019-12-31 10:20:00
#> 4 2019-12-31 10:20:00
#> 5 2019-12-31 10:20:00
#> 6 2019-12-31 10:20:00
#> 7 2019-12-31 10:20:00
#> 8 2019-12-31 10:20:00
#> 9 2019-12-31 10:20:00
#> 10 2019-12-31 10:15:00
#> record_id scientific_name abundance lat_wgs84 lon_wgs84 date_time
#> 1 …107 Pica pica (Linnaeus… 31 65.0027 25.49381 2020-12-31 10:20:00
#> 2 …45 Larus argentatus Po… 1 65.0027 25.49381 2020-12-31 10:20:00
#> 3 …153 Emberiza citrinella… 2 65.0027 25.49381 2020-12-31 10:20:00
#> 4 …49 Columba livia domes… 33 65.0027 25.49381 2020-12-31 10:20:00
#> 5 …117 Corvus corax Linnae… 1 65.0027 25.49381 2020-12-31 10:20:00
#> 6 …111 Corvus monedula Lin… 7 65.0027 25.49381 2020-12-31 10:20:00
#> 7 …161 Sciurus vulgaris Li… 1 65.0027 25.49381 2020-12-31 10:20:00
#> 8 …123 Passer montanus (Li… 28 65.0027 25.49381 2020-12-31 10:20:00
#> 9 …149 Pyrrhula pyrrhula (… 1 65.0027 25.49381 2020-12-31 10:20:00
#> 10 …77 Turdus pilaris Linn… 1 65.0027 25.49381 2020-12-31 10:20:00
#> ...with 0 more record and 6 more variables:
#> coordinates_uncertainty, any_issues, requires_verification, requires_identification,
#> record_reliability, record_quality
Expand Down Expand Up @@ -212,19 +201,19 @@ strict <- c(
record_quality = "expert_verified"
)
permissive <- list(
quality_issues = "both",
record_reliability = c("reliable", "unassessed", "unreliable"),
wild_status = c("wild", "non_wild", "wild_unknown"),
record_quality = c(
"expert_verified", "community_verified", "unassessed", "uncertain",
"erroneous"
)
),
abundance_min = 0
)
c(
strict = finbif_occurrence(filter = strict, count_only = TRUE),
permissive = finbif_occurrence(filter = permissive, count_only = TRUE)
)
#> Error: 1 error occurred:
#> - Invalid name in record reliability: unassessed
#> strict permissive
#> 52654 51733557
```

## Collection
Expand Down

0 comments on commit 078a43b

Please sign in to comment.