Skip to content

Commit

Permalink
version 0.3
Browse files Browse the repository at this point in the history
  • Loading branch information
Gopi Goteti authored and gaborcsardi committed Oct 5, 2014
1 parent c57c54c commit f0f8286
Show file tree
Hide file tree
Showing 8 changed files with 34 additions and 19 deletions.
6 changes: 3 additions & 3 deletions DESCRIPTION
Expand Up @@ -13,7 +13,7 @@ Description: Estimates of rainfall at desired frequency (e.g., 1% annual
and analyze the 1-km GIS files provided by NWS' PF Data Server for
the entire USA. This package also comes with datasets on record point
rainfall measurements provided by NWS-HDSC.
Version: 0.2
Version: 0.3
Author: Gopi Goteti <my.ration.shop@gmail.com>
Maintainer: Gopi Goteti <my.ration.shop@gmail.com>
Depends: R (>= 3.0.2)
Expand All @@ -22,7 +22,7 @@ VignetteBuilder: knitr
Suggests: knitr, raster, maps
License: MIT + file LICENSE
LazyData: true
Packaged: 2014-10-05 04:26:46 UTC; gotetigx
Packaged: 2014-10-05 13:51:17 UTC; gotetigx
NeedsCompilation: no
Repository: CRAN
Date/Publication: 2014-10-05 07:43:50
Date/Publication: 2014-11-29 07:59:53
14 changes: 7 additions & 7 deletions MD5
@@ -1,17 +1,17 @@
bf1a28fdc6e6178e9778fe558561c295 *DESCRIPTION
fcfca620bf8d42cffcf44bd3079aa56a *DESCRIPTION
5faa42f55f737d4922fc24cd063d35d0 *LICENSE
5fab2599e1c7ceecdbc318494c35cbb9 *NAMESPACE
52c77ac656c4df52393488dcfe3a6c1c *NEWS
69479580a04769a7ae16e07ddc88ac74 *NEWS
de6c18eb7478cd2219f350d8a9372b5a *R/data.r
6edf6f2266ce76a61cdc4802d38909a2 *R/extract_freq.r
59658089b0c03c97a8120843695b54cf *R/extract_freq.r
567bdc36550c4642c77f8785f6e8818b *build/vignette.rds
d19cf4b9fa12006bfac5e1f272ab16f5 *data/rain_max_usa.rda
c33273ec348fa4e454c9d1fc9616e817 *data/rain_max_world.rda
9287b1cfdbe026730fd958c39f372cac *inst/doc/rainfreq_demo.R
be1c326bfe933d62f690b8a994c33d1c *inst/doc/rainfreq_demo.Rmd
18c51e575fbd6450fcae24689144d0ed *inst/doc/rainfreq_demo.html
8ac7ed9fd32611a2a8fbea63c0d57868 *man/extract_freq.Rd
251c00f2bc9dccfd8076232488d977c8 *inst/doc/rainfreq_demo.Rmd
eaa28e1b58474776916bc38821418e97 *inst/doc/rainfreq_demo.html
c21518fbc70f19b8faf3b1671d04d6f4 *man/extract_freq.Rd
59b6214b1e84e09bf3a14110d24044ec *man/rain_max_usa.Rd
5587bdc18285cb17bc42c86c1a17e4a9 *man/rain_max_world.Rd
1ecc2f030b754d0d609a4d5ae5e42a82 *man/rainfreq.Rd
be1c326bfe933d62f690b8a994c33d1c *vignettes/rainfreq_demo.Rmd
251c00f2bc9dccfd8076232488d977c8 *vignettes/rainfreq_demo.Rmd
5 changes: 5 additions & 0 deletions NEWS
@@ -1,3 +1,8 @@
Version 0.3, Oct 2014
-----------

* NWS' website (ftp site) sometimes has connectivity issues. If the website is not responding a message is displayed and a value of 10 is returned.

Version 0.2, Oct 2014
-----------

Expand Down
9 changes: 6 additions & 3 deletions R/extract_freq.r
Expand Up @@ -18,7 +18,8 @@
#' @param nws_data_path location of downloaded nws zip files. when
#' flag_read_only is TRUE it defaults to the working directory
#'
#' @return RasterLayer, if flag_down_only is set to FALSE, NULL otherwise
#' @return RasterLayer, if flag_down_only is set to FALSE, NULL otherwise; if
#' the NWS website is not working a value of 10 is returned
#'
#' @author Gopi Goteti
#'
Expand Down Expand Up @@ -101,12 +102,14 @@ extract_freq <- function(region_name = "se",

# check whether the site exists/responds
if (!url.exists(data_source)) {
stop(paste("NWS website", data_source, "is not responding, please try later!"))
message(paste("NWS website", data_source, "is not responding, please try later!"))
return (10)
}
url_name <- paste0(data_source, region_name, "/", file_dump)
if (!url.exists(url_name)) {
stop(paste("NWS website", url_name, "is not responding or does not exist,
message(paste("NWS website", url_name, "is not responding or does not exist,
please check and/or try later!"))
return (10)
}

# download using RCurl
Expand Down
5 changes: 3 additions & 2 deletions inst/doc/rainfreq_demo.Rmd
Expand Up @@ -107,8 +107,9 @@ plot(x_hi, breaks = c(1, 3, 6, 9, 12),

# Future Work

The `extract_freq` function's regional selection criterion does not include US territories such as Puerto Rico and Guam. Future updates would incorporate these regions. Also, functionality could be added to extract the upper and lower limits of the confidence intervals on frequency estimates. Currently, data for Texas and Pacific Northwest is not available from NWS; when such data becomes available, *rainfreq* would be updated accordingly.

* `extract_freq` function's regional selection criterion does not include US territories such as Puerto Rico and Guam. Future updates would incorporate these regions.
* Currently, data for Texas and Pacific Northwest is not available from the NWS. When such data becomes available, the package would be updated accordingly.
* Functionality could be added to extract the upper and lower limits of the confidence intervals on frequency estimates.

[url1_ref]: http://hdsc.nws.noaa.gov/hdsc/pfds/index.html "NWS"
[url2_ref]: http://hdsc.nws.noaa.gov/hdsc/pfds/pfds_gis.html "NWS GIS Data"
Expand Down
6 changes: 5 additions & 1 deletion inst/doc/rainfreq_demo.html
Expand Up @@ -383,7 +383,11 @@ <h1>Graphics</h1>

<h1>Future Work</h1>

<p>The <code>extract_freq</code> function&#39;s regional selection criterion does not include US territories such as Puerto Rico and Guam. Future updates would incorporate these regions. Also, functionality could be added to extract the upper and lower limits of the confidence intervals on frequency estimates. Currently, data for Texas and Pacific Northwest is not available from NWS; when such data becomes available, <em>rainfreq</em> would be updated accordingly.</p>
<ul>
<li><code>extract_freq</code> function&#39;s regional selection criterion does not include US territories such as Puerto Rico and Guam. Future updates would incorporate these regions. </li>
<li>Currently, data for Texas and Pacific Northwest is not available from the NWS. When such data becomes available, the package would be updated accordingly.</li>
<li>Functionality could be added to extract the upper and lower limits of the confidence intervals on frequency estimates. </li>
</ul>

</body>

Expand Down
3 changes: 2 additions & 1 deletion man/extract_freq.Rd
Expand Up @@ -33,7 +33,8 @@ desired. default is FALSE. if set to TRUE a valid file path is required.}
flag_read_only is TRUE it defaults to the working directory}
}
\value{
RasterLayer, if flag_down_only is set to FALSE, NULL otherwise
RasterLayer, if flag_down_only is set to FALSE, NULL otherwise; if
the NWS website is not working a value of 10 is returned
}
\description{
Extract rainfall frequency estimates for desired region of the USA
Expand Down
5 changes: 3 additions & 2 deletions vignettes/rainfreq_demo.Rmd
Expand Up @@ -107,8 +107,9 @@ plot(x_hi, breaks = c(1, 3, 6, 9, 12),

# Future Work

The `extract_freq` function's regional selection criterion does not include US territories such as Puerto Rico and Guam. Future updates would incorporate these regions. Also, functionality could be added to extract the upper and lower limits of the confidence intervals on frequency estimates. Currently, data for Texas and Pacific Northwest is not available from NWS; when such data becomes available, *rainfreq* would be updated accordingly.

* `extract_freq` function's regional selection criterion does not include US territories such as Puerto Rico and Guam. Future updates would incorporate these regions.
* Currently, data for Texas and Pacific Northwest is not available from the NWS. When such data becomes available, the package would be updated accordingly.
* Functionality could be added to extract the upper and lower limits of the confidence intervals on frequency estimates.

[url1_ref]: http://hdsc.nws.noaa.gov/hdsc/pfds/index.html "NWS"
[url2_ref]: http://hdsc.nws.noaa.gov/hdsc/pfds/pfds_gis.html "NWS GIS Data"
Expand Down

0 comments on commit f0f8286

Please sign in to comment.