Skip to content

Instantly share code, notes, and snippets.

@ksonda
ksonda / nldi_mapper.R
Created June 4, 2021 14:47
R NLDI Mapview function
library(mapview)
library(urltools)
library(nhdplusTools)
library(sf)
convert <- function(x) {
for(n in names(x)) {
if(is.character(x[[n]])) {
test <- grepl("^http", x[[n]])
@ksonda
ksonda / server.R
Created January 31, 2020 15:25 — forked from trestletech/server.R
A Shiny app combining the use of dplyr and SQLite. The goal is to demonstrate a full-fledged, database-backed user authorization framework in Shiny.
library(shiny)
library(dplyr)
library(lubridate)
# Load libraries and functions needed to create SQLite databases.
library(RSQLite)
library(RSQLite.extfuns)
saveSQLite <- function(data, name){
path <- dplyr:::db_location(filename=paste0(name, ".sqlite"))