Skip to content

Commit 0502a86

Browse files
committed
v1.1.0 to CRAN
1 parent dc6a7ae commit 0502a86

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

65 files changed

+59
-96
lines changed

.Rbuildignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,8 @@
33
^data-raw$
44
README.Rmd
55
README.md
6+
README.html
7+
^README_FILES/.*
68
cran-comments.md
79
.gitignore
810
.Rhistory

DESCRIPTION

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
Package: WRTDStidal
22
Type: Package
33
Title: Weighted Regression for Water Quality Evaluation in Tidal Waters
4-
Version: 1.0.2.9000
5-
Date: 2016-12-08
4+
Version: 1.1.0
5+
Date: 2017-06-23
66
Author: Marcus W. Beck [aut, cre]
77
Maintainer: Marcus W. Beck <[email protected]>
88
Description: An adaptation for estuaries (tidal waters) of weighted regression
@@ -34,4 +34,4 @@ Depends:
3434
Authors@R: person(given = "Marcus W.", family = "Beck",
3535
role = c("aut","cre"),
3636
email = "[email protected]")
37-
RoxygenNote: 5.0.1
37+
RoxygenNote: 6.0.1

R/all_sims.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
#'
1212
#' @export
1313
#'
14-
#' @seealso \code{\link{daydat}} for example data, \code{\link{lnQ_sim}} for simulating discharge, \code{\link{lnres_err}} for estimating the eror structure of the response variable, and \code{\link{lnres_sim}} for simulating the response variable
14+
#' @seealso \code{\link{daydat}} for example data, \code{\link{lnQ_sim}} for simulating discharge, \code{\link{lnres_err}} for estimating the error structure of the response variable, and \code{\link{lnres_sim}} for simulating the response variable
1515
#'
1616
#' @import dplyr
1717
#'

R/createsrch.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#' Create a grid of half-window widths to evaluate
22
#'
3-
#' Create a grid of all unique combintations of half-window widths to evaluate. The result can be passed to \code{\link{winsrch_grid}}.
3+
#' Create a grid of all unique combinations of half-window widths to evaluate. The result can be passed to \code{\link{winsrch_grid}}.
44
#'
55
#' @param mos numeric vector of half-window widths for months, a value of one indicates twelve months
66
#' @param yrs numeric vector of half-window widths for years, a value of one indicates one-year

R/dec_time.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
#'
99
#' @export
1010
#'
11-
#' @return A named list of four numeric vecors including \code{day_num} (decimal day on an annual scale), \code{month} (month of the year as integer), \code{year}, and \code{dec_time} (decimal time as sum of \code{year} and \code{day_num})
11+
#' @return A named list of four numeric vectors including \code{day_num} (decimal day on an annual scale), \code{month} (month of the year as integer), \code{year}, and \code{dec_time} (decimal time as sum of \code{year} and \code{day_num})
1212
#'
1313
#' @examples
1414
#' dt <- Sys.Date()

R/dynaplot.R

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@
4040
#' # plot using defaults,
4141
#' # defaults to the fiftieth quantile for all years
4242
#' dynaplot(tidfit)
43-
#'
43+
#' \dontrun{
4444
#' # change the defaults
4545
#' dynaplot(tidfit, tau = 0.9, month = 2, years = seq(1980, 1990),
4646
#' col_vec = rainbow(7), alpha = 0.5, size = 3)
@@ -49,6 +49,7 @@
4949
#' data(tidfitmean)
5050
#'
5151
#' dynaplot(tidfitmean)
52+
#' }
5253
dynaplot <- function(dat_in, ...) UseMethod('dynaplot')
5354

5455
#' @rdname dynaplot

R/fitmoplot.R

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
#' @param alpha numeric value indicating transparency of points or lines
1818
#' @param ... arguments passed to other methods
1919
#'
20-
#' @details The plots are similar to those produced by \code{\link{fitplot}} except the values are facetted by month. This allows an evaluation of trends over time independent of seasonal variation. Multiple observations within each month for each year are averaged for a smoother plot.
20+
#' @details The plots are similar to those produced by \code{\link{fitplot}} except the values are faceted by month. This allows an evaluation of trends over time independent of seasonal variation. Multiple observations within each month for each year are averaged for a smoother plot.
2121
#'
2222
#' @import dplyr ggplot2 RColorBrewer
2323
#'
@@ -34,7 +34,7 @@
3434
#'
3535
#' # plot using defaults
3636
#' fitmoplot(tidfit)
37-
#'
37+
#' \dontrun{
3838
#' # get the same plot but use default ggplot settings
3939
#' fitmoplot(tidfit, pretty = FALSE)
4040
#'
@@ -45,7 +45,7 @@
4545
#' fitmoplot(tidfit, predicted = FALSE)
4646
#'
4747
#' # modify the plot as needed using ggplot scales, etc.
48-
#'
48+
#'
4949
#' library(ggplot2)
5050
#'
5151
#' fitmoplot(tidfit, pretty = FALSE, linetype = 'dashed') +
@@ -65,6 +65,7 @@
6565
#' data(tidfitmean)
6666
#'
6767
#' fitmoplot(tidfitmean)
68+
#' }
6869
fitmoplot <- function(dat_in, ...) UseMethod('fitmoplot')
6970

7071
#' @rdname fitmoplot

R/getwts.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
#'
66
#' @param dat_in input tidal object
77
#' @param ref_in row of tidal object as reference for weights
8-
#' @param wt_vars chr string of three elements indicatings names of columns in tidal object that are used for reference row weights
8+
#' @param wt_vars chr string of three elements indicating names of columns in tidal object that are used for reference row weights
99
#' @param wins list of half-window widths for time, year, and flow
1010
#' @param all logical to return individual weights rather than the product of all three, default \code{FALSE}
1111
#' @param slice logical indicating if data are subset by observations within the maximum window width for faster calculations

R/gradcols.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
#'
1111
#' @seealso \code{\link{dynaplot}}, \code{\link{gridplot}}, \code{\link{wtsplot}}
1212
#'
13-
#' @return A character vector of colors in hexidecimal notation.
13+
#' @return A character vector of colors in hexadecimal notation.
1414
#'
1515
#' @examples
1616
#'

R/lnres_err.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
#'
55
#' @param dat_in input \code{\link[base]{data.frame}} that must include discharge and decimal time columns, see example dataset \code{\link{daydat}}
66
#' @param yr numeric year value to use for the stationary model, defaults to the median year
7-
#' @param comps logical indicating ifthe WRTDS model used to get response error measures is also returned, see value.
7+
#' @param comps logical indicating if the WRTDS model used to get response error measures is also returned, see value.
88
#' @param seed optional numeric value for random generation seed
99
#'
1010
#' @details Random errors for a stationary seasonal water quality time series on a daily time step are generated by modelling residuals from an observed dataset. First, a stationary seasonal model is created by fitting a \code{\link{wrtds}} model and estimating an error distribution the residuals using the \code{\link[forecast]{auto.arima}} function. Accumulated standard errors from the regression are also retained for each residual. Random errors using the estimated auto-regressive structures are simulated using \code{\link[stats]{arima.sim}} for the entire year and multiplied by the corresponding standard error estimate from the regression. The entire year is then repeated for every year in the observed time series. The final simulated errors are rescaled to the range of the original residuals that were used to estimate the distribution.

0 commit comments

Comments
 (0)