Skip to content

Commit 6193636

Browse files
Merge pull request #178 from kristenpeach/master
Updates to improve pkgdown website
2 parents 29e64e9 + 25274b3 commit 6193636

File tree

7 files changed

+117
-23
lines changed

7 files changed

+117
-23
lines changed

.Rbuildignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,3 +7,5 @@
77
^\.travis\.yml$
88
^LICENSE$
99
^MAINTENANCE\.md$
10+
^_pkgdown\.yml$
11+
^pkgdown$

DESCRIPTION

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,8 @@ Authors@R: c(
1010
person("Emily", "O'Dean", email = "[email protected]", role = "ctb"),
1111
person("Robyn", "Thiessen-Bock", email = "[email protected]", role = "ctb"),
1212
person("Derek", "Strong", email = "[email protected]", role = "ctb"),
13-
person("Rachel", "Sun", email = "[email protected]", role = "ctb")
13+
person("Rachel", "Sun", email = "[email protected]", role = "ctb"),
14+
person("Jasmine", "Lai", email = "[email protected]", role = "ctb")
1415
)
1516
Description: A set of utilities for working with the Arctic Data Center
1617
(https://arcticdata.io).

R/eml.R

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Helper functions for creating EML metadata
22

3-
#' Create EML entity with physical section from a DataONE PID
3+
#' Create EML entity with physical section from any DataONE PID
44
#'
55
#' @param mn (MNode) Member Node where the PID is associated with an object.
66
#' @param pid (character) The PID of the object to create the sub-tree for.
@@ -74,7 +74,7 @@ pid_to_eml_entity <- function(mn,
7474

7575
#' Create an EML physical object from system metadata
7676
#'
77-
#' This function creates a pre-canned EML physical object from what's in the
77+
#' This function creates an EML physical object based on what's in the
7878
#' System Metadata of an object. Note that it sets an Online Distribution URL
7979
#' of the DataONE v2 resolve service for the PID.
8080
#'
@@ -276,7 +276,7 @@ eml_party <- function(type="associatedParty",
276276
}
277277

278278

279-
#' Create an EML creator
279+
#' Create an EML creator.
280280
#'
281281
#' See [eml_party()] for details.
282282
#'
@@ -298,7 +298,7 @@ eml_creator <- function(...) {
298298
}
299299

300300

301-
#' Create an EML contact
301+
#' Create an EML contact. Contact information is passed on to [eml_party()]
302302
#'
303303
#' See [eml_party()] for details.
304304
#'

R/helpers.R

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ create_dummy_metadata <- function(mn, data_pids = NULL) {
6464

6565
#' Create a test object
6666
#'
67-
#' Create a test data object.
67+
#' Create a test data object. Make sure the member node you use is not a production node.
6868
#'
6969
#' @param mn (MNode) The Member Node.
7070
#'
@@ -121,7 +121,7 @@ create_dummy_object <- function(mn) {
121121

122122
#' Create a test package
123123
#'
124-
#' Create a test data package.
124+
#' Create a full test data package with data objects and 1 metadata object. Size = the number of data objects you want in the dummy package + 1 metadata object.
125125
#'
126126
#' @param mn (MNode) The Member Node.
127127
#' @param size (numeric) The number of files in the package, including the metadata file.
@@ -195,7 +195,7 @@ create_dummy_package <- function(mn, size = 2) {
195195

196196
#' Create a test parent package
197197
#'
198-
#' Create a test parent data package.
198+
#' Create a test parent data package. Make sure the node is not a production node.
199199
#'
200200
#' @param mn (MNode) The Member Node.
201201
#' @param children (character) Child package (resource maps) PIDs.
@@ -324,7 +324,7 @@ create_dummy_enumeratedDomain_dataframe <- function(factors) {
324324

325325
#' Create dummy package with fuller metadata
326326
#'
327-
#' Creates a fuller package than [create_dummy_package()]
327+
#' Creates a more complete package than [create_dummy_package()]
328328
#' but is otherwise based on the same concept. This dummy
329329
#' package includes multiple data objects, responsible parties,
330330
#' geographic locations, method steps, etc.
@@ -579,7 +579,7 @@ list_submissions <- function(mn, from = Sys.Date(), to = Sys.Date(), formatType
579579

580580
#' Read a shapefile from a pid
581581
#'
582-
#' Read a shapefile from a pid that points to the zipped directory of the shapefile and associated files
582+
#' Read a shapefile 'sf' from a pid that points to the zipped directory of the shapefile and associated files
583583
#' on a given member node.
584584
#'
585585
#' @param mn (MNode) A DataOne Member Node
@@ -626,7 +626,7 @@ read_zip_shapefile <- function(mn, pid){
626626

627627
#' Recovers failed submissions
628628
#'
629-
#' Recovers failed submissions and write the new, valid EML to a given path
629+
#' Recovers failed submissions and writes the new, valid EML to a given path
630630
#'
631631
#' @param node (MNode) The Member Node to publish the object to.
632632
#' @param pid The PID of the EML metadata document to be recovered.

README.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,16 +11,12 @@ Note: The package is intended to be used by NCEAS staff and may not make much se
1111

1212
## Installing
1313

14-
We recommend installing from the latest [release](https://github.com/NCEAS/arcticdatautils/releases) (aka tag) instead of from `master`. Install the latest release with the [`remotes`](https://github.com/r-lib/remotes) package:
14+
To install the latest version of this package we recommend installing from Github:
1515

1616
```r
17-
remotes::install_github("nceas/arcticdatautils@*release")
18-
```
19-
20-
If you're feeling adventurous, you can install from the bleeding edge:
2117

22-
```r
2318
remotes::install_github("nceas/arcticdatautils")
19+
2420
```
2521

2622
## Contributing
@@ -64,3 +60,7 @@ If you *do* want to run integration tests
6460
options(dataone_test_token = "{YOUR_TOKEN_HERE}") # <- Modify this line
6561
devtools::test()
6662
```
63+
64+
<div>
65+
<p align="center"> <a href="https://www.nceas.ucsb.edu/"> <img src="https://www.nceas.ucsb.edu/files/logos/NCEAS/NCEAS-full%20logo-4C.jpg" width="250px" align="center" /></a> <a rel="license" href="http://creativecommons.org/licenses/by-sa/4.0/"><img alt="Creative Commons License" style="border-width:0" src="https://i.creativecommons.org/l/by-sa/4.0/88x31.png" /> </p>
66+
</div>

_pkgdown.yml

Lines changed: 90 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,3 +2,93 @@ navbar:
22
right:
33
- icon: fa-github
44
href: https://github.com/NCEAS/arcticdatautils
5+
6+
reference:
7+
- title: Access functions
8+
desc: High-level utility functions for getting and setting access rules for DataONE objects
9+
contents:
10+
- set_rights_holder
11+
- set_access
12+
- remove_access
13+
- set_rights_and_access
14+
- set_public_read
15+
- remove_public_read
16+
- is_public_read
17+
18+
- title: DataOne Functions
19+
desc: Helper functions for the dataone package
20+
contents:
21+
- is_token_set
22+
- get_token
23+
- is_token_expired
24+
- get_mn_base_url
25+
- is_authorized
26+
27+
- title: NetCDF Functions
28+
desc: Get a data.frame of attributes from a NetCDF object
29+
contents:
30+
- get_ncdf4_attributes
31+
- get_token
32+
- is_token_expired
33+
- get_mn_base_url
34+
- is_authorized
35+
36+
- title: Sysmeta Function
37+
desc: Utility function for modifying System Metadata objects
38+
contents:
39+
- get_all_sysmeta
40+
41+
42+
- title: Package editing functions
43+
desc: Functions for managing package contents
44+
contents:
45+
- publish_object
46+
- update_object
47+
- publish_update
48+
- create_resource_map
49+
- update_resource_map
50+
- set_file_name
51+
- reformat_file_name
52+
53+
- title: Functions to help test a package
54+
desc: Various helper functions for things like testing a package
55+
contents:
56+
- starts_with('create_')
57+
- get_orcid_name
58+
- get_orcid_email
59+
60+
- title: EML Functions
61+
desc: Helper functions for creating EML metadata
62+
contents:
63+
- starts_with('pid_')
64+
- starts_with('eml_')
65+
- sysmeta_to_eml_physical
66+
- get_orcid_email
67+
- set_abstract
68+
- which_in_eml
69+
- reorder_pids
70+
71+
- title: Environment Functions
72+
desc: Function related to loading configuriation based upon the environment
73+
contents:
74+
- starts_with('env_')
75+
76+
- title: Format Functions
77+
desc: Functions related to data object formats
78+
contents:
79+
- guess_format_id
80+
- format_eml
81+
- format_iso
82+
83+
- title: QA Function
84+
desc: Function related to metadata quality
85+
contents:
86+
- mdq_run
87+
88+
89+
90+
91+
92+
93+
94+

index.md

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,14 +11,15 @@ Note: The package is intended to be used by NCEAS staff and may not make much se
1111

1212
## Installing
1313

14-
We recommend installing from the latest [release](https://github.com/NCEAS/arcticdatautils/releases) (aka tag) instead of from `master`. Install the latest release with the [`remotes`](https://github.com/r-lib/remotes) package:
1514

16-
```r
17-
remotes::install_github("nceas/arcticdatautils@*release")
18-
```
19-
20-
If you're feeling adventurous, you can install from the bleeding edge:
15+
To install the latest version of this package we recommend installing from Github:
2116

2217
```r
18+
2319
remotes::install_github("nceas/arcticdatautils")
20+
2421
```
22+
23+
<div>
24+
<p align="center"> <a href="https://www.nceas.ucsb.edu/"><img src="https://www.nceas.ucsb.edu/files/logos/NCEAS/NCEAS-full%20logo-4C.jpg" width="250px" align="center" /></a> <a rel="license" href="http://creativecommons.org/licenses/by-sa/4.0/"><img alt="Creative Commons License" style="border-width:0" src="https://i.creativecommons.org/l/by-sa/4.0/88x31.png" /> </p>
25+
</div>

0 commit comments

Comments
 (0)