share_spec: Share data with the Open Specy community

View source: R/share_spec.R

share_specR Documentation

Share data with the Open Specy community

Description

This helper function shares spectral data and metadata with the Open Specy community.

Please note: that share_spec() only provides basic sharing functionality if used interactively. This means that files are only formatted and saved for sharing but are not sent automatically. This only works with hosted instances of Open Specy.

Usage

share_spec(x, ...)

## Default S3 method:
share_spec(x, ...)

## S3 method for class 'OpenSpecy'
share_spec(x, file = NULL, share = "system", credentials = NULL, ...)

Arguments

x

a list object of class OpenSpecy.

file

file to share (optional).

share

accepts any local directory to save the spectrum for later sharing via email to wincowger@gmail.com; "system" (default) uses the Open Specy package directory at system.file("extdata", package = "OpenSpecy"); if a correct API token exists, "cloud" shares the spectrum with the cloud.

credentials

a named list of credentials for cloud sharing; required if share = "cloud").

...

further arguments passed to the submethods.

Value

share_spec() returns only messages/warnings.

Author(s)

Zacharias Steinmetz, Win Cowger

See Also

read_text(); digest(); sessionInfo()

Examples

## Not run: 
data("raman_hdpe")
share_spec(raman_hdpe,
           metadata = list(
             user_name = "Win Cowger",
             spectrum_type = "FTIR",
             spectrum_identity = "PE",
             license = "CC BY-NC"
           ))

## End(Not run)


OpenSpecy documentation built on Nov. 26, 2023, 1:09 a.m.