diff --git a/DESCRIPTION b/DESCRIPTION index 0d43ad3392dcc7b7f06926de997be2bff60847ae..cfeac6c5670a1a02758c293e2f07e1232f481b02 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -20,7 +20,6 @@ Collate: 'getSiteFileData.r' 'getDataFromFile.r' 'getParameterInfo.r' - 'getPreLoadedData.r' 'checkStartEndDate.r' 'dateFormatCheck.r' 'formatCheckDate.r' @@ -36,10 +35,8 @@ Collate: 'populateParameterINFO.r' 'removeDuplicates.r' 'getDVData.r' - 'getPreLoadedDailyData.r' 'getDailyDataFromFile.r' 'getSampleData.r' - 'getPreLoadedSampleData.r' 'getSampleDataFromFile.r' 'getMetaData.r' 'mergeReport.r' diff --git a/NAMESPACE b/NAMESPACE index cfa3034906a489e8501b0b57268d954fae68b2f6..ad346ed18573994ad4461bb6b628b92988d356d0 100644 --- a/NAMESPACE +++ b/NAMESPACE @@ -12,9 +12,6 @@ export(getDataAvailability) export(getDataFromFile) export(getMetaData) export(getParameterInfo) -export(getPreLoadedDailyData) -export(getPreLoadedData) -export(getPreLoadedSampleData) export(getQWData) export(getQWDataFromFile) export(getRDB1Data) diff --git a/R/getPreLoadedDailyData.r b/R/getPreLoadedDailyData.r deleted file mode 100644 index 11df232210e3ba5b2697107bba3452a4fe6b9801..0000000000000000000000000000000000000000 --- a/R/getPreLoadedDailyData.r +++ /dev/null @@ -1,22 +0,0 @@ -#' Import Preloaded Daily Data for WRTDS use -#' -#' This function is intended to convert daily data that is already loaded into the R enviornment to the WRTDS daily data frame. -#' -#' @param loadedData dataframe that is already loaded in R session -#' @param qUnit number 1 is cubic feet per second, 2 is cubic meters per second, 3 is 10^3 cubic feet per second, and 4 is 10^3 cubic meters per second -#' @param interactive logical Option for interactive mode. If true, there is user interaction for error handling and data checks. -#' @keywords data import WRTDS -#' @export -#' @return Daily dataframe -#' @examples -#' Daily <- getPreLoadedDailyData(ChoptankRiverFlow, interactive=FALSE) -getPreLoadedDailyData <- function (loadedData,qUnit=1,interactive=TRUE){ - data <- getPreLoadedData(loadedData) - convertQ<-c(35.314667,1) - qConvert<-convertQ[qUnit] - if (interactive){ - if(qUnit==1) cat("\n the input discharge are assumed to be in cubic feet per second\nif they are in cubic meters per second, then the call to getPreLoadedDailyData should specify qUnit=2\n") - } - localDaily <- populateDaily(data,qConvert, interactive=interactive) - return(localDaily) -} diff --git a/R/getPreLoadedData.r b/R/getPreLoadedData.r deleted file mode 100644 index 3dcdbe298dc8545c91f430579be2d9fcf1a8a87e..0000000000000000000000000000000000000000 --- a/R/getPreLoadedData.r +++ /dev/null @@ -1,31 +0,0 @@ -#' Convert Preloaded Flow Data -#' -#' Imports data from data already pre-loaded into the R workspace. Specifically used to import water flow data for use in the WRTDS package. -#' For WRTDS usage, the first column is expected to be dates, the second column measured values. -#' The third column is optional, it contains any remark codes. -#' -#' @param rawData dataframe data already loaded into R workspace -#' @keywords data import -#' @return retval dataframe with dateTime, value, and code columns -#' @export -#' @examples -#' ChoptankRiverFlow <- ChoptankRiverFlow -#' rawData <- getPreLoadedData(ChoptankRiverFlow) -#' rawDataSample <- getPreLoadedData(ChoptankRiverNitrate) -getPreLoadedData <- function (rawData){ - retval <- as.data.frame(rawData, stringsAsFactors=FALSE) - if(ncol(retval) == 2){ - names(retval) <- c('dateTime', 'value') - } else if (ncol(retval) == 3){ - names(retval) <- c('dateTime', 'code', 'value') - } - retval$dateTime <- as.character(retval$dateTime) - if(dateFormatCheck(retval$dateTime)){ - retval$dateTime <- as.Date(retval$dateTime) - } else { - retval$dateTime <- as.Date(retval$dateTime,format="%m/%d/%Y") - } - - retval$value <- as.numeric(retval$value) - return (retval) -} diff --git a/R/getPreLoadedSampleData.r b/R/getPreLoadedSampleData.r deleted file mode 100644 index 2862993ab1cbf2f6e317cb4c9535b570660b2cd9..0000000000000000000000000000000000000000 --- a/R/getPreLoadedSampleData.r +++ /dev/null @@ -1,17 +0,0 @@ -#' Import Preloaded Sample Data for WRTDS use -#' -#' This function is intended to convert sample data that is already loaded into the R enviornment to the WRTDS daily data frame. -#' -#' @param loadedData dataframe that is already loaded in R session -#' @param interactive logical Option for interactive mode. If true, there is user interaction for error handling and data checks. -#' @keywords data import WRTDS -#' @export -#' @return Sample dataframe -#' @examples -#' Sample <- getPreLoadedSampleData(ChoptankRiverNitrate, interactive=FALSE) -getPreLoadedSampleData <- function (loadedData,interactive=TRUE){ - - compressedData <- compressData(loadedData,interactive=interactive) - Sample <- populateSampleColumns(compressedData) - return(Sample) -} diff --git a/man/getPreLoadedDailyData.Rd b/man/getPreLoadedDailyData.Rd deleted file mode 100644 index 8be9941cee8a1e22b9c42a2f1e1783955a01990b..0000000000000000000000000000000000000000 --- a/man/getPreLoadedDailyData.Rd +++ /dev/null @@ -1,34 +0,0 @@ -\name{getPreLoadedDailyData} -\alias{getPreLoadedDailyData} -\title{Import Preloaded Daily Data for WRTDS use} -\usage{ - getPreLoadedDailyData(loadedData, qUnit = 1, - interactive = TRUE) -} -\arguments{ - \item{loadedData}{dataframe that is already loaded in R - session} - - \item{qUnit}{number 1 is cubic feet per second, 2 is - cubic meters per second, 3 is 10^3 cubic feet per second, - and 4 is 10^3 cubic meters per second} - - \item{interactive}{logical Option for interactive mode. - If true, there is user interaction for error handling and - data checks.} -} -\value{ - Daily dataframe -} -\description{ - This function is intended to convert daily data that is - already loaded into the R enviornment to the WRTDS daily - data frame. -} -\examples{ -Daily <- getPreLoadedDailyData(ChoptankRiverFlow, interactive=FALSE) -} -\keyword{WRTDS} -\keyword{data} -\keyword{import} - diff --git a/man/getPreLoadedData.Rd b/man/getPreLoadedData.Rd deleted file mode 100644 index 8aefe64af90936bf7ab631ee19de8d33baa2fdec..0000000000000000000000000000000000000000 --- a/man/getPreLoadedData.Rd +++ /dev/null @@ -1,29 +0,0 @@ -\name{getPreLoadedData} -\alias{getPreLoadedData} -\title{Convert Preloaded Flow Data} -\usage{ - getPreLoadedData(rawData) -} -\arguments{ - \item{rawData}{dataframe data already loaded into R - workspace} -} -\value{ - retval dataframe with dateTime, value, and code columns -} -\description{ - Imports data from data already pre-loaded into the R - workspace. Specifically used to import water flow data - for use in the WRTDS package. For WRTDS usage, the first - column is expected to be dates, the second column - measured values. The third column is optional, it - contains any remark codes. -} -\examples{ -ChoptankRiverFlow <- ChoptankRiverFlow -rawData <- getPreLoadedData(ChoptankRiverFlow) -rawDataSample <- getPreLoadedData(ChoptankRiverNitrate) -} -\keyword{data} -\keyword{import} - diff --git a/man/getPreLoadedSampleData.Rd b/man/getPreLoadedSampleData.Rd deleted file mode 100644 index 1e8834a400df76773c56f0d66f2f281f4bffabf2..0000000000000000000000000000000000000000 --- a/man/getPreLoadedSampleData.Rd +++ /dev/null @@ -1,29 +0,0 @@ -\name{getPreLoadedSampleData} -\alias{getPreLoadedSampleData} -\title{Import Preloaded Sample Data for WRTDS use} -\usage{ - getPreLoadedSampleData(loadedData, interactive = TRUE) -} -\arguments{ - \item{loadedData}{dataframe that is already loaded in R - session} - - \item{interactive}{logical Option for interactive mode. - If true, there is user interaction for error handling and - data checks.} -} -\value{ - Sample dataframe -} -\description{ - This function is intended to convert sample data that is - already loaded into the R enviornment to the WRTDS daily - data frame. -} -\examples{ -Sample <- getPreLoadedSampleData(ChoptankRiverNitrate, interactive=FALSE) -} -\keyword{WRTDS} -\keyword{data} -\keyword{import} - diff --git a/man/getSampleData.Rd b/man/getSampleData.Rd index aa83390b01f2f112a4441e86fe4491d60803de99..03563421128d0064c62f7f0f5666acfec800454d 100644 --- a/man/getSampleData.Rd +++ b/man/getSampleData.Rd @@ -27,8 +27,9 @@ } \description{ Imports data from NWIS web service. This function gets - the data from here: \url{http://qwwebservices.usgs.gov/} - A list of parameter codes can be found here: + the data from here: + \url{http://nwis.waterdata.usgs.gov/nwis/qwdata/} A list + of parameter codes can be found here: \url{http://nwis.waterdata.usgs.gov/nwis/pmcodes/} A list of statistic codes can be found here: \url{http://nwis.waterdata.usgs.gov/nwis/help/?read_file=stat&format=table} diff --git a/vignettes/dataRetrieval-concordance.tex b/vignettes/dataRetrieval-concordance.tex index 9c4b7d7c852ad58e193f20fa190ef5178afa4338..4e0d91d301a16c0d0b2a53fc95bfe3c5efe616cf 100644 --- a/vignettes/dataRetrieval-concordance.tex +++ b/vignettes/dataRetrieval-concordance.tex @@ -1,9 +1,9 @@ \Sconcordance{concordance:dataRetrieval.tex:dataRetrieval.Rnw:% 1 49 1 50 0 1 6 11 1 1 5 46 1 113 0 7 1 42 0 21 1 10 % -0 16 1 9 0 21 1 5 0 6 1 8 0 14 1 42 0 17 1 3 0 15 1 6 % -0 16 1 10 0 5 1 8 0 20 1 3 0 18 1 1 0 21 1 9 0 20 1 4 % -0 4 1 18 0 29 1 6 0 10 1 10 0 14 1 21 0 19 1 5 0 19 1 % -5 0 17 1 8 0 14 1 15 0 16 1 5 0 9 1 5 0 62 1 6 0 14 1 % -17 0 36 1 5 0 24 1 5 0 20 1 37 0 13 1 10 0 22 1 5 0 5 % -1 13 0 5 1 5 0 11 1 5 0 7 1 5 0 16 1 51 0 15 1 49 0 7 % -1 32 0 24 1 18 0 8 1 5 0 56 1} +0 16 1 9 0 21 1 5 0 6 1 8 0 14 1 42 0 17 1 4 0 15 1 6 % +0 16 1 10 0 5 1 8 0 20 1 4 0 18 1 3 0 21 1 10 0 20 1 % +4 0 4 1 18 0 29 1 8 0 10 1 10 0 14 1 21 0 19 1 5 0 19 % +1 5 0 17 1 8 0 14 1 15 0 16 1 5 0 9 1 5 0 62 1 6 0 11 % +1 1 4 36 1 5 0 24 1 5 0 20 1 38 0 13 1 10 0 79 1 5 0 % +5 1 13 0 5 1 5 0 11 1 5 0 7 1 5 0 16 1 51 0 15 1 49 0 % +7 1 32 0 24 1 19 0 8 1 5 0 56 1} diff --git a/vignettes/dataRetrieval.Rnw b/vignettes/dataRetrieval.Rnw index a5f0489a095d67ab7e4dac61b4aff024ad1666c0..7e5ab3318dde9a3a50b62ddfbb2ec421a5700d4b 100644 --- a/vignettes/dataRetrieval.Rnw +++ b/vignettes/dataRetrieval.Rnw @@ -557,7 +557,8 @@ For every sample, the EGRET package requires a pair of numbers to define an inte For the more complex example case, let us say dp is reported as \verb@<@0.01 and pp is reported as 0.3. We know that the total must be at least 0.3 and could be as much as 0.31. Therefore, ConcLow=0.3 and ConcHigh=0.31. Another case would be if dp is reported as \verb@<@0.005 and pp is reported \verb@<@0.2. We know in this case that the true value could be as low as zero, but could be as high as 0.205. Therefore, in this case, ConcLow=NA and ConcHigh=0.205. The Sample dataframe for the example data is therefore: <<thirdExample,echo=FALSE>>= -getPreLoadedSampleData(DF) + compressedData <- compressData(DF) + Sample <- populateSampleColumns(compressedData) @ @@ -654,7 +655,64 @@ library(EGRET) multiPlotDataOverview() @ + \clearpage + +%------------------------------------------------------------ +\section{Summary} +%------------------------------------------------------------ + +The following table summarizes the data retrieval functions: + +\begin{table}[!ht] +\begin{minipage}{\linewidth} +\begin{center} +\caption{dataRetrieval functions} +\begin{tabular}{lll} + \hline +Data Type & Function Name & Description \\ + \hline + Daily (raw) & retrieveNWISData & Raw USGS daily data \\ + Daily & getDVData & USGS daily values \\ + Daily & getDailyDataFromFile & User generated daily data \\ + Sample (raw) & retrieveNWISqwData & Raw USGS water quality data \\ + Sample (raw) & getRawQWData & Raw Water Quality Data Portal data \\ + Sample (raw) & getQWDataFromFile & Raw user generated water quality data \\ + Sample (processed) & getQWData & USGS Water Quality Portal data \\ + Sample (processed) & getWQPData & General Water Quality Portal\\ + Sample & getSampleData & USGS water quality data\\ + Sample & getSTORETSampleData & STORET Water Quality Data Portal data \\ + Sample & getSampleDataFromFile & User generated sample data \\ + Unit (raw) & retrieveUnitNWISData & Raw USGS instantaneous data \\ + Information & getMetaData & USGS station and parameter code information \\ + Information & getParameterInfo & USGS parameter code information \\ + Information & getSiteFileData & USGS station information \\ + Information & getDataAvailability & Data available at USGS stations \\ + \hline +\end{tabular} +\end{center} +\end{minipage} +\end{table} + +\begin{table}[!ht] +\begin{minipage}{\linewidth} +\begin{center} +\caption{dataRetrieval functions 2} +\begin{tabular}{l p{4cm} p{4cm}} + \hline +Data Type & EGRET Functions & Other Retrieval Functions \\ + \hline + Daily Data & getDVData \par getDailyDataFromFile & retrieveNWISData \\ + Water Quality Sample Data & getSampleData \par getSTORETSampleData \par getSampleDataFromFile \par & retrieveNWISqwData \par getRawQWData \par getQWDataFromFile \par getQWData \par getWQPData\\ + Unit Data& & retrieveUnitNWISData \\ + Meta Data & getMetaData & getParameterInfo \par getSiteFileData \par getDataAvailability \\ + \hline +\end{tabular} +\end{center} +\end{minipage} +\end{table} + + \appendix %------------------------------------------------------------ diff --git a/vignettes/dataRetrieval.log b/vignettes/dataRetrieval.log index 6a240d1a982e9677f9d9e9f686f81ef0f98b546e..4acb9c778fa3c2977883cd63ef49e1a647ef02bb 100644 --- a/vignettes/dataRetrieval.log +++ b/vignettes/dataRetrieval.log @@ -1,4 +1,4 @@ -This is pdfTeX, Version 3.1415926-2.3-1.40.12 (MiKTeX 2.9) (preloaded format=pdflatex 2012.1.6) 13 SEP 2013 16:58 +This is pdfTeX, Version 3.1415926-2.3-1.40.12 (MiKTeX 2.9) (preloaded format=pdflatex 2012.1.6) 28 OCT 2013 16:27 entering extended mode **dataRetrieval.tex (D:\LADData\RCode\dataRetrieval\vignettes\dataRetrieval.tex @@ -698,90 +698,94 @@ Overfull \vbox (21.68121pt too high) has occurred while \output is active [] [10] -Package color Info: Redefining color shadecolor on input line 526. -Package color Info: Redefining color shadecolor on input line 544. +Overfull \vbox (21.68121pt too high) has occurred while \output is active [] + + +[11] +Package color Info: Redefining color shadecolor on input line 527. +Package color Info: Redefining color shadecolor on input line 545. -Overfull \hbox (30.64148pt too wide) in paragraph at lines 554--555 +Overfull \hbox (30.64148pt too wide) in paragraph at lines 555--556 []\OT1/ptm/m/n/10.95 Parameter in-for-ma-tion is ob-tained from []$\OT1/pcr/m/n /10.95 http : / / nwis . waterdata . usgs . gov / nwis / pmcodes/$[] [] -Package color Info: Redefining color shadecolor on input line 565. +Package color Info: Redefining color shadecolor on input line 566. Overfull \vbox (21.68121pt too high) has occurred while \output is active [] -[11] -Package color Info: Redefining color shadecolor on input line 583. -Package color Info: Redefining color shadecolor on input line 602. +[12] +Package color Info: Redefining color shadecolor on input line 585. +Package color Info: Redefining color shadecolor on input line 606. LaTeX Warning: No positions in optional float specifier. - Default added (so using `tbp') on input line 618. + Default added (so using `tbp') on input line 623. -<figure/getNWIStemperaturePlot.pdf, id=227, 505.89pt x 505.89pt> +<figure/getNWIStemperaturePlot.pdf, id=236, 505.89pt x 505.89pt> File: figure/getNWIStemperaturePlot.pdf Graphic file (type pdf) <use figure/getNWIStemperaturePlot.pdf> Package pdftex.def Info: figure/getNWIStemperaturePlot.pdf used on input line 6 -20. +25. (pdftex.def) Requested size: 448.07928pt x 448.07928pt. Overfull \vbox (21.68121pt too high) has occurred while \output is active [] -[12] +[13] Overfull \vbox (21.68121pt too high) has occurred while \output is active [] -[13 <D:/LADData/RCode/dataRetrieval/vignettes/figure/getNWIStemperaturePlot.pdf +[14 <D:/LADData/RCode/dataRetrieval/vignettes/figure/getNWIStemperaturePlot.pdf >] -Package color Info: Redefining color shadecolor on input line 639. -Package color Info: Redefining color shadecolor on input line 652. +Package color Info: Redefining color shadecolor on input line 644. +Package color Info: Redefining color shadecolor on input line 657. Overfull \vbox (21.68121pt too high) has occurred while \output is active [] -[14] -Package color Info: Redefining color shadecolor on input line 688. -Package color Info: Redefining color shadecolor on input line 710. +[15] +Package color Info: Redefining color shadecolor on input line 693. +Package color Info: Redefining color shadecolor on input line 717. LaTeX Warning: No positions in optional float specifier. - Default added (so using `tbp') on input line 719. + Default added (so using `tbp') on input line 726. -<figure/getQWtemperaturePlot.pdf, id=255, 505.89pt x 505.89pt> +<figure/getQWtemperaturePlot.pdf, id=264, 505.89pt x 505.89pt> File: figure/getQWtemperaturePlot.pdf Graphic file (type pdf) <use figure/getQWtemperaturePlot.pdf> -Package pdftex.def Info: figure/getQWtemperaturePlot.pdf used on input line 721 +Package pdftex.def Info: figure/getQWtemperaturePlot.pdf used on input line 728 . (pdftex.def) Requested size: 448.07378pt x 448.07928pt. Overfull \vbox (21.68121pt too high) has occurred while \output is active [] -[15] +[16] Overfull \vbox (21.68121pt too high) has occurred while \output is active [] -[16 <D:/LADData/RCode/dataRetrieval/vignettes/figure/getQWtemperaturePlot.pdf>] +[17 <D:/LADData/RCode/dataRetrieval/vignettes/figure/getQWtemperaturePlot.pdf>] -Overfull \hbox (50.793pt too wide) in paragraph at lines 734--735 +Overfull \hbox (50.793pt too wide) in paragraph at lines 741--742 \OT1/ptm/m/n/10.95 There are ad-di-tional data sets avail-able on the Wa-ter Qu al-ity Data Por-tal ([]$\OT1/pcr/m/n/10.95 http : / / www . waterqualitydata .$ [] -Package color Info: Redefining color shadecolor on input line 737. -LaTeX Font Info: Try loading font information for TS1+pcr on input line 739. +Package color Info: Redefining color shadecolor on input line 744. +LaTeX Font Info: Try loading font information for TS1+pcr on input line 746. ("C:\Program Files (x86)\MiKTeX 2.9\tex\latex\psnfss\ts1pcr.fd" File: ts1pcr.fd 2001/06/04 font definitions for TS1/pcr. ) -Package color Info: Redefining color shadecolor on input line 772. +Package color Info: Redefining color shadecolor on input line 779. -Overfull \hbox (5.25568pt too wide) in paragraph at lines 781--781 +Overfull \hbox (5.25568pt too wide) in paragraph at lines 788--788 [][]\OT1/pcr/m/n/10.95 url_uv[] []<-[] []\OT1/pcr/b/n/10.95 constructNWISURL[][ ]\OT1/pcr/m/n/10.95 (siteNumber,[][]"00060"[][],startDate,endDate,[][]\TS1/pcr/ m/n/10.95 '\OT1/pcr/m/n/10.95 uv\TS1/pcr/m/n/10.95 '[][]\OT1/pcr/m/n/10.95 )[][ @@ -792,21 +796,17 @@ m/n/10.95 '\OT1/pcr/m/n/10.95 uv\TS1/pcr/m/n/10.95 '[][]\OT1/pcr/m/n/10.95 )[][ Overfull \vbox (21.68121pt too high) has occurred while \output is active [] -[17] -Package color Info: Redefining color shadecolor on input line 802. -Package color Info: Redefining color shadecolor on input line 821. - -Overfull \vbox (21.68121pt too high) has occurred while \output is active [] - - [18] -Package color Info: Redefining color shadecolor on input line 876. -Package color Info: Redefining color shadecolor on input line 889. +Package color Info: Redefining color shadecolor on input line 809. +Package color Info: Redefining color shadecolor on input line 828. Overfull \vbox (21.68121pt too high) has occurred while \output is active [] [19] +Package color Info: Redefining color shadecolor on input line 883. +Package color Info: Redefining color shadecolor on input line 896. + Overfull \vbox (21.68121pt too high) has occurred while \output is active [] @@ -815,36 +815,38 @@ Overfull \vbox (21.68121pt too high) has occurred while \output is active [] [21] -Package color Info: Redefining color shadecolor on input line 978. - Overfull \vbox (21.68121pt too high) has occurred while \output is active [] [22] -Package color Info: Redefining color shadecolor on input line 1029. -LaTeX Font Info: Try loading font information for OMS+pcr on input line 1034 +Overfull \vbox (21.68121pt too high) has occurred while \output is active [] + + +[23] +Package color Info: Redefining color shadecolor on input line 1017. +LaTeX Font Info: Try loading font information for OMS+pcr on input line 1022 . ("C:\Program Files (x86)\MiKTeX 2.9\tex\latex\psnfss\omspcr.fd" File: omspcr.fd ) LaTeX Font Info: Font shape `OMS/pcr/m/n' in size <10.95> not available -(Font) Font shape `OMS/cmsy/m/n' tried instead on input line 1034. +(Font) Font shape `OMS/cmsy/m/n' tried instead on input line 1022. +Package color Info: Redefining color shadecolor on input line 1046. Overfull \vbox (21.68121pt too high) has occurred while \output is active [] -[23] -Package color Info: Redefining color shadecolor on input line 1058. -Package color Info: Redefining color shadecolor on input line 1078. +[24] +Package color Info: Redefining color shadecolor on input line 1066. -Overfull \hbox (44.67563pt too wide) in paragraph at lines 1102--1102 +Overfull \hbox (44.67563pt too wide) in paragraph at lines 1091--1091 [] \OT1/pcr/m/n/10.95 First day of the discharge record is 2000-01-01 and last day is 2013-01-01[] [] -Overfull \hbox (44.67563pt too wide) in paragraph at lines 1102--1102 +Overfull \hbox (44.67563pt too wide) in paragraph at lines 1091--1091 [] \OT1/pcr/m/n/10.95 The first sample is from 2000-01-04 and the last sample i s from 2012-12-18[] [] @@ -853,146 +855,150 @@ s from 2012-12-18[] Overfull \vbox (21.68121pt too high) has occurred while \output is active [] -[24] -Package color Info: Redefining color shadecolor on input line 1134. +[25] +Package color Info: Redefining color shadecolor on input line 1123. LaTeX Warning: No positions in optional float specifier. - Default added (so using `tbp') on input line 1140. + Default added (so using `tbp') on input line 1129. -<figure/egretEx.pdf, id=315, 505.89pt x 505.89pt> +<figure/egretEx.pdf, id=325, 505.89pt x 505.89pt> File: figure/egretEx.pdf Graphic file (type pdf) <use figure/egretEx.pdf> -Package pdftex.def Info: figure/egretEx.pdf used on input line 1142. +Package pdftex.def Info: figure/egretEx.pdf used on input line 1131. (pdftex.def) Requested size: 448.07378pt x 448.07928pt. Overfull \vbox (21.68121pt too high) has occurred while \output is active [] -[25] +[26] Overfull \vbox (21.68121pt too high) has occurred while \output is active [] -[26 <D:/LADData/RCode/dataRetrieval/vignettes/figure/egretEx.pdf>] -Package color Info: Redefining color shadecolor on input line 1168. -Package color Info: Redefining color shadecolor on input line 1178. +[27 <D:/LADData/RCode/dataRetrieval/vignettes/figure/egretEx.pdf>] +Overfull \vbox (21.68121pt too high) has occurred while \output is active [] -Overfull \hbox (51.24562pt too wide) in paragraph at lines 1189--1189 -[] \OT1/pcr/m/n/10.95 Sample1 <- localSample[!duplicated(localSample[c("DecYea -r","ConcHigh")]),][] - [] -Package color Info: Redefining color shadecolor on input line 1196. -Package color Info: Redefining color shadecolor on input line 1211. +[28 -Overfull \vbox (21.68121pt too high) has occurred while \output is active [] +] +Package color Info: Redefining color shadecolor on input line 1214. +Package color Info: Redefining color shadecolor on input line 1224. +Overfull \hbox (51.24562pt too wide) in paragraph at lines 1235--1235 +[] \OT1/pcr/m/n/10.95 Sample1 <- localSample[!duplicated(localSample[c("DecYea +r","ConcHigh")]),][] + [] -[27 +Package color Info: Redefining color shadecolor on input line 1242. +Package color Info: Redefining color shadecolor on input line 1257. -] -Overfull \hbox (157.60596pt too wide) in paragraph at lines 1220--1221 +Overfull \hbox (157.60596pt too wide) in paragraph at lines 1266--1267 \OT1/ptm/m/n/10.95 C:/Users/userA/Documents/R/win-library/2.15/dataRetrieval, a nd the de-fault for a Mac: /Users/userA/Library/R/2.15/library/dataRetrieval. [] -Package color Info: Redefining color shadecolor on input line 1224. +Package color Info: Redefining color shadecolor on input line 1270. Overfull \vbox (21.68121pt too high) has occurred while \output is active [] -[28] +[29] Overfull \vbox (21.68121pt too high) has occurred while \output is active [] -[29] +[30] Overfull \vbox (21.68121pt too high) has occurred while \output is active [] -[30 +[31] +Overfull \vbox (21.68121pt too high) has occurred while \output is active [] + + +[32 ] Overfull \vbox (21.68121pt too high) has occurred while \output is active [] -[31] +[33] Overfull \vbox (21.68121pt too high) has occurred while \output is active [] -[32 +[34 ] -Package color Info: Redefining color shadecolor on input line 1411. -Package color Info: Redefining color shadecolor on input line 1448. +Package color Info: Redefining color shadecolor on input line 1457. +Package color Info: Redefining color shadecolor on input line 1495. Overfull \vbox (21.68121pt too high) has occurred while \output is active [] -[33 +[35 ] -Overfull \hbox (11.82567pt too wide) in paragraph at lines 1466--1466 +Overfull \hbox (11.82567pt too wide) in paragraph at lines 1513--1513 []\OT1/pcr/m/n/10.95 Suspended sediment concentration (SSC) 1980-10-01 1991-09- 30 3651 mg/l[] [] -<table1.png, id=366, 554.07pt x 125.71968pt> +<table1.png, id=381, 554.07pt x 125.71968pt> File: table1.png Graphic file (type png) <use table1.png> -Package pdftex.def Info: table1.png used on input line 1485. +Package pdftex.def Info: table1.png used on input line 1532. (pdftex.def) Requested size: 554.06865pt x 125.71936pt. Overfull \vbox (21.68121pt too high) has occurred while \output is active [] -[34 <D:/LADData/RCode/dataRetrieval/vignettes/table1.png>] -Underfull \hbox (badness 1983) in paragraph at lines 1501--1502 +[36 <D:/LADData/RCode/dataRetrieval/vignettes/table1.png>] +Underfull \hbox (badness 1983) in paragraph at lines 1548--1549 []\OT1/ptm/m/n/10.95 Hirsch, R. M., Moyer, D. L. and Arch-field, S. A. (2010), Weighted Re-gres-sions on [] -Underfull \hbox (badness 1221) in paragraph at lines 1501--1502 +Underfull \hbox (badness 1221) in paragraph at lines 1548--1549 \OT1/ptm/m/n/10.95 Time, Dis-charge, and Sea-son (WRTDS), with an Ap-pli-ca-tio n to Chesa-peake Bay River [] -Underfull \hbox (badness 2443) in paragraph at lines 1501--1502 +Underfull \hbox (badness 2443) in paragraph at lines 1548--1549 \OT1/ptm/m/n/10.95 In-puts. JAWRA Jour-nal of the Amer-i-can Wa-ter Re-sources As-so-ci-a-tion, 46: 857-880. [] -Underfull \hbox (badness 3690) in paragraph at lines 1501--1502 +Underfull \hbox (badness 3690) in paragraph at lines 1548--1549 \OT1/ptm/m/n/10.95 doi: 10.1111/j.1752-1688.2010.00482.x []$\OT1/pcr/m/n/10.95 http : / / onlinelibrary . wiley . com / doi /$ [] -Package atveryend Info: Empty hook `BeforeClearDocument' on input line 1508. +Package atveryend Info: Empty hook `BeforeClearDocument' on input line 1555. Overfull \vbox (21.68121pt too high) has occurred while \output is active [] -[35 +[37 ] -Package atveryend Info: Empty hook `AfterLastShipout' on input line 1508. +Package atveryend Info: Empty hook `AfterLastShipout' on input line 1555. (D:\LADData\RCode\dataRetrieval\vignettes\dataRetrieval.aux) -Package atveryend Info: Executing hook `AtVeryEndDocument' on input line 1508. -Package atveryend Info: Executing hook `AtEndAfterFileList' on input line 1508. +Package atveryend Info: Executing hook `AtVeryEndDocument' on input line 1555. +Package atveryend Info: Executing hook `AtEndAfterFileList' on input line 1555. Package rerunfilecheck Info: File `dataRetrieval.out' has not changed. -(rerunfilecheck) Checksum: E39EB3526BB75384BBF16131BFA2BB3D;2017. +(rerunfilecheck) Checksum: 30AE4E6A4E0A9704D03232DABCF58698;2061. ) Here is how much of TeX's memory you used: - 8258 strings out of 494045 - 123267 string characters out of 3145961 + 8264 strings out of 494045 + 123333 string characters out of 3145961 228280 words of memory out of 3000000 - 11325 multiletter control sequences out of 15000+200000 + 11326 multiletter control sequences out of 15000+200000 30981 words of font info for 68 fonts, out of 3000000 for 9000 715 hyphenation exceptions out of 8191 - 44i,15n,42p,912b,451s stack positions out of 5000i,500n,10000p,200000b,50000s + 44i,15n,42p,912b,449s stack positions out of 5000i,500n,10000p,200000b,50000s {C:/Program Files (x86)/MiKTeX 2.9/fonts/enc/dvips/fontname/8r.enc}<C:/Progra m Files (x86)/MiKTeX 2.9/fonts/type1/public/amsfonts/cm/cmmi10.pfb><C:/Program Files (x86)/MiKTeX 2.9/fonts/type1/public/amsfonts/cm/cmsy10.pfb><C:/Program Fi @@ -1002,9 +1008,9 @@ les (x86)/MiKTeX 2.9/fonts/type1/urw/courier/ucrb8a.pfb><C:/Program Files (x86) /type1/urw/times/utmb8a.pfb><C:/Program Files (x86)/MiKTeX 2.9/fonts/type1/urw/ times/utmr8a.pfb><C:/Program Files (x86)/MiKTeX 2.9/fonts/type1/urw/times/utmri 8a.pfb> -Output written on dataRetrieval.pdf (35 pages, 293807 bytes). +Output written on dataRetrieval.pdf (37 pages, 297127 bytes). PDF statistics: - 446 PDF objects out of 1000 (max. 8388607) - 92 named destinations out of 1000 (max. 500000) - 253 words of extra memory for PDF output out of 10000 (max. 10000000) + 465 PDF objects out of 1000 (max. 8388607) + 97 named destinations out of 1000 (max. 500000) + 261 words of extra memory for PDF output out of 10000 (max. 10000000) diff --git a/vignettes/dataRetrieval.pdf b/vignettes/dataRetrieval.pdf index 12dbd481c0db79e2de797ca002821f25c4a58030..53bb4ac34aeb114a9960c7c3ab88d14834993f6e 100644 Binary files a/vignettes/dataRetrieval.pdf and b/vignettes/dataRetrieval.pdf differ diff --git a/vignettes/dataRetrieval.synctex.gz b/vignettes/dataRetrieval.synctex.gz index dc0e8ed4e7b2077a33cea66d8a1a3ae8d8c5fbc7..ad1c132034b02d18b3718135c829518311cba83a 100644 Binary files a/vignettes/dataRetrieval.synctex.gz and b/vignettes/dataRetrieval.synctex.gz differ diff --git a/vignettes/dataRetrieval.tex b/vignettes/dataRetrieval.tex index ece61138119d7c905aeb890cdafd135c8fde485d..709a75ac99d19439dc6ca258bdc5abd5daede792 100644 --- a/vignettes/dataRetrieval.tex +++ b/vignettes/dataRetrieval.tex @@ -330,8 +330,8 @@ Once the site-ID is known, the next required input for USGS data retrievals is t Not every station will measure all parameters. A short list of commonly measured parameters is shown in Table \ref{tab:params}. -% latex table generated in R 3.0.1 by xtable 1.7-1 package -% Fri Sep 13 16:57:38 2013 +% latex table generated in R 3.0.2 by xtable 1.7-1 package +% Mon Oct 28 16:27:10 2013 \begin{table}[ht] \centering \begin{tabular}{rll} @@ -356,8 +356,8 @@ For real-time data, the parameter code and site ID will suffice. For most varia \url{http://nwis.waterdata.usgs.gov/nwis/help/?read_file=stat&format=table} Some common stat codes are shown in Table \ref{tab:stat}. -% latex table generated in R 3.0.1 by xtable 1.7-1 package -% Fri Sep 13 16:57:38 2013 +% latex table generated in R 3.0.2 by xtable 1.7-1 package +% Mon Oct 28 16:27:10 2013 \begin{table}[ht] \centering \begin{tabular}{rll} @@ -484,6 +484,7 @@ It is also possible to only request parameter information for a subset of variab \hlcom{# This pulls out just the daily data:} \hlstd{ChoptankDailyData} \hlkwb{<-} \hlkwd{subset}\hlstd{(ChoptankAvailableData,} \hlstr{"dv"} \hlopt{==} \hlstd{service)} + \hlcom{# This pulls out the mean:} \hlstd{ChoptankDailyData} \hlkwb{<-} \hlkwd{subset}\hlstd{(ChoptankDailyData,} \hlstr{"00003"} \hlopt{==} \hlstd{statCd)} @@ -492,8 +493,8 @@ It is also possible to only request parameter information for a subset of variab \end{knitrout} -% latex table generated in R 3.0.1 by xtable 1.7-1 package -% Fri Sep 13 16:57:40 2013 +% latex table generated in R 3.0.2 by xtable 1.7-1 package +% Mon Oct 28 16:27:11 2013 \begin{table}[ht] \centering \begin{tabular}{rlllll} @@ -501,7 +502,7 @@ It is also possible to only request parameter information for a subset of variab & shortName & Start & End & Count & Units \\ \hline 1 & Temperature, water & 2010-10-01 & 2012-05-09 & 529 & deg C \\ - 2 & Stream flow, mean. daily & 1948-01-01 & 2013-09-12 & 23997 & ft3/s \\ + 2 & Stream flow, mean. daily & 1948-01-01 & 2013-10-27 & 24042 & ft3/s \\ 3 & Specific conductance & 2010-10-01 & 2012-05-09 & 527 & uS/cm @25C \\ 4 & Suspended sediment concentration (SSC) & 1980-10-01 & 1991-09-30 & 3651 & mg/l \\ 5 & Suspended sediment discharge & 1980-10-01 & 1991-09-30 & 3652 & tons/day \\ @@ -568,6 +569,7 @@ The dates (start and end) need to be in the format \texttt{"}YYYY-MM-DD\texttt{" \hlstd{parameterCd} \hlkwb{<-} \hlstr{"00060"} \hlcom{# Discharge (cfs)} \hlstd{startDate} \hlkwb{<-} \hlstr{""} \hlcom{# Will request earliest date} \hlstd{endDate} \hlkwb{<-} \hlstr{""} \hlcom{# Will request latest date} + \hlstd{discharge} \hlkwb{<-} \hlkwd{retrieveNWISData}\hlstd{(siteNumber,} \hlstd{parameterCd, startDate, endDate)} \end{alltt} @@ -586,8 +588,10 @@ Another example that doesn't use the defaults would be a request for mean and ma \hlstd{statCd} \hlkwb{<-} \hlkwd{c}\hlstd{(}\hlstr{"00001"}\hlstd{,}\hlstr{"00003"}\hlstd{)} \hlcom{# Mean and maximum} \hlstd{startDate} \hlkwb{<-} \hlstr{"2012-01-01"} \hlstd{endDate} \hlkwb{<-} \hlstr{"2012-05-01"} + \hlstd{temperatureAndFlow} \hlkwb{<-} \hlkwd{retrieveNWISData}\hlstd{(siteNumber, parameterCd,} \hlstd{startDate, endDate,} \hlkwc{StatCd}\hlstd{=statCd)} + \hlstd{temperatureAndFlow} \hlkwb{<-} \hlkwd{renameColumns}\hlstd{(temperatureAndFlow)} \end{alltt} \end{kframe} @@ -602,13 +606,14 @@ An example of plotting the above data (Figure \ref{fig:getNWIStemperaturePlot}): \definecolor{shadecolor}{rgb}{0.969, 0.969, 0.969}\color{fgcolor}\begin{kframe} \begin{alltt} \hlkwd{par}\hlstd{(}\hlkwc{mar}\hlstd{=}\hlkwd{c}\hlstd{(}\hlnum{5}\hlstd{,}\hlnum{5}\hlstd{,}\hlnum{5}\hlstd{,}\hlnum{5}\hlstd{))} + \hlkwd{with}\hlstd{(temperatureAndFlow,} \hlkwd{plot}\hlstd{(} - \hlstd{datetime, Temperature_water_01,} + \hlstd{datetime, Temperature_water_degrees_Celsius_Max_01,} \hlkwc{xlab}\hlstd{=}\hlstr{"Date"}\hlstd{,}\hlkwc{ylab}\hlstd{=}\hlstr{"Temperature [C]"} \hlstd{))} \hlkwd{par}\hlstd{(}\hlkwc{new}\hlstd{=}\hlnum{TRUE}\hlstd{)} \hlkwd{with}\hlstd{(temperatureAndFlow,} \hlkwd{plot}\hlstd{(} - \hlstd{datetime, Stream_flow_mean_daily,} + \hlstd{datetime, Discharge_cubic_feet_per_second,} \hlkwc{col}\hlstd{=}\hlstr{"red"}\hlstd{,}\hlkwc{type}\hlstd{=}\hlstr{"l"}\hlstd{,}\hlkwc{xaxt}\hlstd{=}\hlstr{"n"}\hlstd{,}\hlkwc{yaxt}\hlstd{=}\hlstr{"n"}\hlstd{,}\hlkwc{xlab}\hlstd{=}\hlstr{""}\hlstd{,}\hlkwc{ylab}\hlstd{=}\hlstr{""}\hlstd{,}\hlkwc{axes}\hlstd{=}\hlnum{FALSE} \hlstd{))} \hlkwd{axis}\hlstd{(}\hlnum{4}\hlstd{,}\hlkwc{col}\hlstd{=}\hlstr{"red"}\hlstd{,}\hlkwc{col.axis}\hlstd{=}\hlstr{"red"}\hlstd{)} @@ -691,8 +696,10 @@ To get USGS water quality data from water samples collected at the streamgage (a \hlstd{parameterCd} \hlkwb{<-} \hlkwd{c}\hlstd{(}\hlstr{"00618"}\hlstd{,}\hlstr{"71851"}\hlstd{)} \hlstd{startDate} \hlkwb{<-} \hlstr{"1979-10-11"} \hlstd{endDate} \hlkwb{<-} \hlstr{"2012-12-18"} + \hlstd{dissolvedNitrate} \hlkwb{<-} \hlkwd{getRawQWData}\hlstd{(siteNumber, parameterCd,} \hlstd{startDate, endDate)} + \hlstd{dissolvedNitrateSimple} \hlkwb{<-} \hlkwd{getQWData}\hlstd{(siteNumber, parameterCd,} \hlstd{startDate, endDate)} \hlkwd{names}\hlstd{(dissolvedNitrateSimple)} @@ -835,8 +842,8 @@ There are 4750 data points, and 4750 days. Details of the Daily dataframe are listed below: -% latex table generated in R 3.0.1 by xtable 1.7-1 package -% Fri Sep 13 16:57:53 2013 +% latex table generated in R 3.0.2 by xtable 1.7-1 package +% Mon Oct 28 16:27:21 2013 \begin{table}[ht] \centering \begin{tabular}{rllll} @@ -944,8 +951,8 @@ As an example to understand how the dataRetrieval package handles a more complex \begin{center} -% latex table generated in R 3.0.1 by xtable 1.7-1 package -% Fri Sep 13 16:57:54 2013 +% latex table generated in R 3.0.2 by xtable 1.7-1 package +% Mon Oct 28 16:27:22 2013 \begin{table}[ht] \centering \begin{tabular}{rllrlrlr} @@ -974,26 +981,7 @@ For every sample, the EGRET package requires a pair of numbers to define an inte For the more complex example case, let us say dp is reported as \verb@<@0.01 and pp is reported as 0.3. We know that the total must be at least 0.3 and could be as much as 0.31. Therefore, ConcLow=0.3 and ConcHigh=0.31. Another case would be if dp is reported as \verb@<@0.005 and pp is reported \verb@<@0.2. We know in this case that the true value could be as low as zero, but could be as high as 0.205. Therefore, in this case, ConcLow=NA and ConcHigh=0.205. The Sample dataframe for the example data is therefore: -\begin{knitrout} -\definecolor{shadecolor}{rgb}{0.969, 0.969, 0.969}\color{fgcolor}\begin{kframe} -\begin{verbatim} - Date ConcLow ConcHigh Uncen ConcAve Julian Month -1 2003-02-15 0.520 0.520 1 0.520 55927 2 -2 2003-06-30 0.310 0.310 1 0.310 56062 6 -3 2004-09-15 0.205 0.205 1 0.205 56505 9 -4 2005-01-30 0.430 0.430 1 0.430 56642 1 -5 2005-05-30 0.050 0.050 1 0.050 56762 5 -6 2005-10-30 0.020 0.020 1 0.020 56915 10 - Day DecYear MonthSeq SinDY CosDY -1 46 2003 1838 0.70407 0.7101 -2 182 2003 1842 0.02575 -0.9997 -3 259 2005 1857 -0.96251 -0.2712 -4 30 2005 1861 0.48506 0.8745 -5 151 2005 1865 0.52943 -0.8484 -6 304 2006 1870 -0.87861 0.4775 -\end{verbatim} -\end{kframe} -\end{knitrout} + \FloatBarrier @@ -1081,6 +1069,7 @@ Finally, there is a function called mergeReport that will look at both the Daily \hlstd{parameterCd} \hlkwb{<-} \hlstr{"00631"} \hlcom{# Nitrate} \hlstd{startDate} \hlkwb{<-} \hlstr{"2000-01-01"} \hlstd{endDate} \hlkwb{<-} \hlstr{"2013-01-01"} + \hlstd{Daily} \hlkwb{<-} \hlkwd{getDVData}\hlstd{(siteNumber,} \hlstr{"00060"}\hlstd{, startDate, endDate)} \end{alltt} \begin{verbatim} @@ -1094,10 +1083,10 @@ There are 4750 data points, and 4750 days. Discharge Record is 4750 days long, which is 13 years First day of the discharge record is 2000-01-01 and last day is 2013-01-01 - The water quality record has 220 samples + The water quality record has 222 samples The first sample is from 2000-01-04 and the last sample is from 2012-12-18 Discharge: Minimum, mean and maximum 0.00991 4.55 246 - Concentration: Minimum, mean and maximum 0.2 1.3 2.4 + Concentration: Minimum, mean and maximum 0.2 1.2 2.4 Percentage of the sample values that are censored is 0 % \end{verbatim} \begin{alltt} @@ -1146,7 +1135,64 @@ As has been mentioned, the data is specifically formatted to be used with the EG \end{knitrout} + \clearpage + +%------------------------------------------------------------ +\section{Summary} +%------------------------------------------------------------ + +The following table summarizes the data retrieval functions: + +\begin{table}[!ht] +\begin{minipage}{\linewidth} +\begin{center} +\caption{dataRetrieval functions} +\begin{tabular}{lll} + \hline +Data Type & Function Name & Description \\ + \hline + Daily (raw) & retrieveNWISData & Raw USGS daily data \\ + Daily & getDVData & USGS daily values \\ + Daily & getDailyDataFromFile & User generated daily data \\ + Sample (raw) & retrieveNWISqwData & Raw USGS water quality data \\ + Sample (raw) & getRawQWData & Raw Water Quality Data Portal data \\ + Sample (raw) & getQWDataFromFile & Raw user generated water quality data \\ + Sample (processed) & getQWData & USGS Water Quality Portal data \\ + Sample (processed) & getWQPData & General Water Quality Portal\\ + Sample & getSampleData & USGS water quality data\\ + Sample & getSTORETSampleData & STORET Water Quality Data Portal data \\ + Sample & getSampleDataFromFile & User generated sample data \\ + Unit (raw) & retrieveUnitNWISData & Raw USGS instantaneous data \\ + Information & getMetaData & USGS station and parameter code information \\ + Information & getParameterInfo & USGS parameter code information \\ + Information & getSiteFileData & USGS station information \\ + Information & getDataAvailability & Data available at USGS stations \\ + \hline +\end{tabular} +\end{center} +\end{minipage} +\end{table} + +\begin{table}[!ht] +\begin{minipage}{\linewidth} +\begin{center} +\caption{dataRetrieval functions 2} +\begin{tabular}{l p{4cm} p{4cm}} + \hline +Data Type & EGRET Functions & Other Retrieval Functions \\ + \hline + Daily Data & getDVData \par getDailyDataFromFile & retrieveNWISData \\ + Water Quality Sample Data & getSampleData \par getSTORETSampleData \par getSampleDataFromFile \par & retrieveNWISqwData \par getRawQWData \par getQWDataFromFile \par getQWData \par getWQPData\\ + Unit Data& & retrieveUnitNWISData \\ + Meta Data & getMetaData & getParameterInfo \par getSiteFileData \par getDataAvailability \\ + \hline +\end{tabular} +\end{center} +\end{minipage} +\end{table} + + \appendix %------------------------------------------------------------ @@ -1239,8 +1285,8 @@ After installing the package, you need to open the library each time you re-star \label{sec:appendix2INFO} %------------------------------------------------------------ -% latex table generated in R 3.0.1 by xtable 1.7-1 package -% Fri Sep 13 16:57:57 2013 +% latex table generated in R 3.0.2 by xtable 1.7-1 package +% Mon Oct 28 16:27:25 2013 \begin{table}[ht] \centering \begin{tabular}{rl} @@ -1305,8 +1351,8 @@ After installing the package, you need to open the library each time you re-star There are 62 columns returned from the water quality portal. -% latex table generated in R 3.0.1 by xtable 1.7-1 package -% Fri Sep 13 16:57:57 2013 +% latex table generated in R 3.0.2 by xtable 1.7-1 package +% Mon Oct 28 16:27:25 2013 \begin{table}[ht] \centering \begin{tabular}{rl} @@ -1362,8 +1408,8 @@ There are 62 columns returned from the water quality portal. \FloatBarrier -% latex table generated in R 3.0.1 by xtable 1.7-1 package -% Fri Sep 13 16:57:57 2013 +% latex table generated in R 3.0.2 by xtable 1.7-1 package +% Mon Oct 28 16:27:25 2013 \begin{table}[ht] \centering \begin{tabular}{rl} @@ -1413,6 +1459,7 @@ There are a few steps that are required in order to create a table in a Microsof \hlstd{availableData} \hlkwb{<-} \hlkwd{getDataAvailability}\hlstd{(siteNumber)} \hlstd{dailyData} \hlkwb{<-} \hlstd{availableData[}\hlstr{"dv"} \hlopt{==} \hlstd{availableData}\hlopt{$}\hlstd{service,]} \hlstd{dailyData} \hlkwb{<-} \hlstd{dailyData[}\hlstr{"00003"} \hlopt{==} \hlstd{dailyData}\hlopt{$}\hlstd{statCd,]} + \hlstd{tableData} \hlkwb{<-} \hlkwd{with}\hlstd{(dailyData,} \hlkwd{data.frame}\hlstd{(} \hlkwc{shortName}\hlstd{=srsname,} @@ -1432,7 +1479,7 @@ There are a few steps that are required in order to create a table in a Microsof 5 Suspended sediment discharge 1980-10-01 End Count Units 1 2012-05-09 529 deg C -2 2013-09-12 23997 ft3/s +2 2013-10-27 24042 ft3/s 3 2012-05-09 527 uS/cm @25C 4 1991-09-30 3651 mg/l 5 1991-09-30 3652 tons/day diff --git a/vignettes/dataRetrieval.toc b/vignettes/dataRetrieval.toc index ef8524f7f3c3e26edbfe9f68d70bbfddc825a03f..274fbcf6fdcc0aafb85ad13d8d2de65bdab11c45 100644 --- a/vignettes/dataRetrieval.toc +++ b/vignettes/dataRetrieval.toc @@ -5,26 +5,27 @@ \contentsline {subsection}{\numberline {2.2}Site Information}{9}{subsection.2.2} \contentsline {subsubsection}{\numberline {2.2.1}getSiteFileData}{9}{subsubsection.2.2.1} \contentsline {subsubsection}{\numberline {2.2.2}getDataAvailability}{9}{subsubsection.2.2.2} -\contentsline {subsection}{\numberline {2.3}Parameter Information}{11}{subsection.2.3} -\contentsline {subsection}{\numberline {2.4}Daily Values}{11}{subsection.2.4} -\contentsline {subsection}{\numberline {2.5}Unit Values}{14}{subsection.2.5} -\contentsline {subsection}{\numberline {2.6}Water Quality Values}{15}{subsection.2.6} -\contentsline {subsection}{\numberline {2.7}STORET Water Quality Retrievals}{17}{subsection.2.7} -\contentsline {subsection}{\numberline {2.8}URL Construction}{17}{subsection.2.8} -\contentsline {section}{\numberline {3}Data Retrievals Structured For Use In The EGRET Package}{18}{section.3} -\contentsline {subsection}{\numberline {3.1}INFO Data}{18}{subsection.3.1} -\contentsline {subsection}{\numberline {3.2}Daily Data}{18}{subsection.3.2} -\contentsline {subsection}{\numberline {3.3}Sample Data}{19}{subsection.3.3} -\contentsline {subsection}{\numberline {3.4}Censored Values: Summation Explanation}{21}{subsection.3.4} -\contentsline {subsection}{\numberline {3.5}User-Generated Data Files}{22}{subsection.3.5} -\contentsline {subsubsection}{\numberline {3.5.1}getDailyDataFromFile}{22}{subsubsection.3.5.1} -\contentsline {subsubsection}{\numberline {3.5.2}getSampleDataFromFile}{23}{subsubsection.3.5.2} -\contentsline {subsection}{\numberline {3.6}Merge Report}{24}{subsection.3.6} -\contentsline {subsection}{\numberline {3.7}EGRET Plots}{25}{subsection.3.7} -\contentsline {section}{\numberline {A}Getting Started in R}{27}{appendix.A} -\contentsline {subsection}{\numberline {A.1}New to R?}{27}{subsection.A.1} -\contentsline {subsection}{\numberline {A.2}R User: Installing dataRetrieval}{27}{subsection.A.2} -\contentsline {section}{\numberline {B}Columns Names}{28}{appendix.B} -\contentsline {subsection}{\numberline {B.1}INFO dataframe}{28}{subsection.B.1} -\contentsline {subsection}{\numberline {B.2}Water Quality Portal}{30}{subsection.B.2} -\contentsline {section}{\numberline {C}Creating tables in Microsoft from R}{33}{appendix.C} +\contentsline {subsection}{\numberline {2.3}Parameter Information}{12}{subsection.2.3} +\contentsline {subsection}{\numberline {2.4}Daily Values}{12}{subsection.2.4} +\contentsline {subsection}{\numberline {2.5}Unit Values}{15}{subsection.2.5} +\contentsline {subsection}{\numberline {2.6}Water Quality Values}{16}{subsection.2.6} +\contentsline {subsection}{\numberline {2.7}STORET Water Quality Retrievals}{18}{subsection.2.7} +\contentsline {subsection}{\numberline {2.8}URL Construction}{18}{subsection.2.8} +\contentsline {section}{\numberline {3}Data Retrievals Structured For Use In The EGRET Package}{19}{section.3} +\contentsline {subsection}{\numberline {3.1}INFO Data}{19}{subsection.3.1} +\contentsline {subsection}{\numberline {3.2}Daily Data}{19}{subsection.3.2} +\contentsline {subsection}{\numberline {3.3}Sample Data}{20}{subsection.3.3} +\contentsline {subsection}{\numberline {3.4}Censored Values: Summation Explanation}{22}{subsection.3.4} +\contentsline {subsection}{\numberline {3.5}User-Generated Data Files}{23}{subsection.3.5} +\contentsline {subsubsection}{\numberline {3.5.1}getDailyDataFromFile}{23}{subsubsection.3.5.1} +\contentsline {subsubsection}{\numberline {3.5.2}getSampleDataFromFile}{24}{subsubsection.3.5.2} +\contentsline {subsection}{\numberline {3.6}Merge Report}{25}{subsection.3.6} +\contentsline {subsection}{\numberline {3.7}EGRET Plots}{26}{subsection.3.7} +\contentsline {section}{\numberline {4}Summary}{28}{section.4} +\contentsline {section}{\numberline {A}Getting Started in R}{28}{appendix.A} +\contentsline {subsection}{\numberline {A.1}New to R?}{29}{subsection.A.1} +\contentsline {subsection}{\numberline {A.2}R User: Installing dataRetrieval}{29}{subsection.A.2} +\contentsline {section}{\numberline {B}Columns Names}{30}{appendix.B} +\contentsline {subsection}{\numberline {B.1}INFO dataframe}{30}{subsection.B.1} +\contentsline {subsection}{\numberline {B.2}Water Quality Portal}{32}{subsection.B.2} +\contentsline {section}{\numberline {C}Creating tables in Microsoft from R}{35}{appendix.C} diff --git a/vignettes/figure/egretEx.pdf b/vignettes/figure/egretEx.pdf index 9823ef135123fa89ebefcefd98c6ef280a928d47..caa10ccace269b25cbaefb74fe0a4cf9ab83427e 100644 Binary files a/vignettes/figure/egretEx.pdf and b/vignettes/figure/egretEx.pdf differ diff --git a/vignettes/figure/getNWIStemperaturePlot.pdf b/vignettes/figure/getNWIStemperaturePlot.pdf index ca5ab31503b708ee8727a6ba0843628de26d008f..7638a399f4604d17cf3e04a70ab85da1d300acb6 100644 Binary files a/vignettes/figure/getNWIStemperaturePlot.pdf and b/vignettes/figure/getNWIStemperaturePlot.pdf differ diff --git a/vignettes/figure/getQWtemperaturePlot.pdf b/vignettes/figure/getQWtemperaturePlot.pdf index 944e5fe09f9215b6537e2040994057236640fd7f..868ab54872ebe7fd8d25fda94962c9d4e24d76bb 100644 Binary files a/vignettes/figure/getQWtemperaturePlot.pdf and b/vignettes/figure/getQWtemperaturePlot.pdf differ