ncss-tech / soilReports

An R package that assists with the setup and operation of a collection of soil data summary, comparison, and evaluation reports. These reports are primarily used by USDA-NRCS soil scientists in both initial and update mapping.
15 stars 5 forks source link

pedon report: link to NASIS data via web report #62

Open dylanbeaudette opened 7 years ago

dylanbeaudette commented 7 years ago

@brownag and @smroecker might be interested in linking pedon IDs in reports to NASIS / LIMS reports. Re-setting the browser path is only recommended for those who cannot stand IE.

library(soilDB)
x <- fetchNASIS(rmHzErrors = FALSE)

options(browser='C:/Users/Dylan.Beaudette/AppData/Local/Google/Chrome/Application/chrome.exe')

showReport <- function(pedon_id, ...) {
  report.url <- 'https://nasis.sc.egov.usda.gov/NasisReportsWebSite/limsreport.aspx?report_name=Pedon_Site_Description(usepedonid)&pedon_id='
  report.url <- paste0(report.url, pedon_id)
  utils::browseURL(report.url, ...)
}

showReport(x$pedon_id[1])

showReport('2013CA6304020')