docker pull ubuntu
docker run -it ubuntu bash
cat /etc/lsb-release
DISTRIB_ID=Ubuntu
#'@references \url{http://aa.usno.navy.mil/data/docs/RS_OneYear.php} | |
#'@return A 3 x 365 data.frame of sunrise, sunset, date where times are in GMT | |
#'@examples \dontrun{ | |
#' sunsetrise_yr(year = 2015, lon_deg = 80, lon_min = 26, lat_deg = 25, lat_min = 5, tz = 5) | |
#' } | |
sunsetrise_yr <- function(year, lon_sign = -1, lon_deg, lon_min, lat_sign = 1, lat_deg, lat_min, tz, tz_sign = 1){ | |
url <- "http://aa.usno.navy.mil" | |
dt <- knitcitations::read.bibtex("foo.bib") | |
dt <- dt[grep("doi", tolower(dt)),] | |
res <- stringr::str_extract(dt, "(?=10)(.*?)(?<=\\s)") | |
res <- as.character(sapply(res, function(x) substring(x, 1, nchar(x) - 3))) | |
(res <- res[!is.na(res)]) | |
# paste0("http://dx.doi.org/", res) | |
library(dataone) | |
cn <- CNode("PROD") | |
mn <- getMNode(cn, "urn:node:KNB") | |
dt <- getPackage(mn, id = "resourceMap_kgordon.4.57") | |
unzip(dt) | |
# list.files("resourceMap_kgordon_4_57/data") | |
dt <- read.csv("resourceMap_kgordon_4_57/data/cbfs.140.3-Oneida_Benthos_1956_to_present.csv", | |
stringsAsFactors = FALSE) |
Package: datasets.test | |
Title: What the Package Does (one line, title case) | |
Version: 0.0.0.9000 | |
Authors@R: c(person("Joseph", "Stachelek", email = "[email protected]", role = c("aut", "cre"))) | |
Description: What the package does (one paragraph). | |
Depends: | |
R (>= 3.3.3) | |
Imports: | |
datasets | |
License: GPL (>= 2) |
.First <- function() { | |
options( | |
repos = c(CRAN = "https://cran.rstudio.com/"), | |
browserNLdisabled = TRUE, | |
deparse.max.lines = 2) | |
} | |
if (interactive()) { | |
suppressMessages(require(devtools)) | |
} |
#Setup########################################################################## | |
message("Checking for a personal library...") | |
if (!dir.exists(Sys.getenv("R_LIBS_USER"))) { | |
warning("Personal library not found, creating one...") | |
dir.create(Sys.getenv("R_LIBS_USER"), recursive = TRUE) | |
message("Registering newly created personal library...") | |
.libPaths(Sys.getenv("R_LIBS_USER")) | |
} else { |
library(rjags) | |
data(iris) | |
independent <- iris$Petal.Length | |
dependent <- matrix(iris$Petal.Width) | |
lm.m <- lm(independent~dependent) | |
dependent <- cbind(1, dependent) |
# http://math.utoledo.edu/~mleite/math-EES-seminar/week1Baysean.pdf | |
data(iris) | |
# Estimation #### | |
y <- iris$Sepal.Length | |
y_bar <- mean(y) | |
y_sd <- sd(y) | |
n <- length(y) |
{ | |
"translatorID": "7a81d945-7d9c-4f8c-bd7b-4226c1cadasd", | |
"label": "KNB", | |
"creator": "Joseph Stachelek", | |
"target": "https://knb.ecoinformatics.org/", | |
"minVersion": "3.0", | |
"maxVersion": "", | |
"priority": 100, | |
"inRepository": true, | |
"translatorType": 4, |