Closed spencerpease closed 5 years ago
R/addAQILegend.R:11:1: style: Lines should not be more than 100 characters.
#' @description This function is a convenience wrapper around \code{graphics::legend()}. It will show the AQI colors and
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addAQILegend.R:11:121: style: Trailing whitespace is superfluous.
#' @description This function is a convenience wrapper around \code{graphics::legend()}. It will show the AQI colors and
^
R/addAQILegend.R:21:1: style: Trailing whitespace is superfluous.
^~
R/addAQILegend.R:22:12: style: Put spaces around all infix operators.
legend( x=x, y=y, col=col, legend=legend, pch=pch, title=title, ... )
~^~
R/addAQILegend.R:22:17: style: Put spaces around all infix operators.
legend( x=x, y=y, col=col, legend=legend, pch=pch, title=title, ... )
~^~
R/addAQILegend.R:22:24: style: Put spaces around all infix operators.
legend( x=x, y=y, col=col, legend=legend, pch=pch, title=title, ... )
~^~
R/addAQILegend.R:22:36: style: Put spaces around all infix operators.
legend( x=x, y=y, col=col, legend=legend, pch=pch, title=title, ... )
~^~
R/addAQILegend.R:22:48: style: Put spaces around all infix operators.
legend( x=x, y=y, col=col, legend=legend, pch=pch, title=title, ... )
~^~
R/addAQILegend.R:22:59: style: Put spaces around all infix operators.
legend( x=x, y=y, col=col, legend=legend, pch=pch, title=title, ... )
~^~
R/addAQILegend.R:23:1: style: Trailing whitespace is superfluous.
^~
R/addAQILines.R:6:3: style: Trailing whitespace is superfluous.
#'
^
R/addAQILines.R:10:1: style: Trailing whitespace is superfluous.
^~
R/addAQILines.R:11:21: style: Put spaces around all infix operators.
graphics::abline(h=AQI$breaks_24, col=AQI$colors, ...)
~^~
R/addAQILines.R:11:40: style: Put spaces around all infix operators.
graphics::abline(h=AQI$breaks_24, col=AQI$colors, ...)
~^~
R/addAQILines.R:12:1: style: Trailing whitespace is superfluous.
^~
R/addAQIStackedBar.R:19:16: style: Put spaces around all infix operators.
l <- usr[2]-width*(usr[2]-usr[1])
~^~
R/addAQIStackedBar.R:19:22: style: Put spaces around all infix operators.
l <- usr[2]-width*(usr[2]-usr[1])
~^~
R/addAQIStackedBar.R:19:23: style: Place a space before left parenthesis, except in a function call.
l <- usr[2]-width*(usr[2]-usr[1])
^
R/addAQIStackedBar.R:19:30: style: Put spaces around all infix operators.
l <- usr[2]-width*(usr[2]-usr[1])
~^~
R/addAQIStackedBar.R:23:16: style: Put spaces around all infix operators.
r <- usr[1]+width*(usr[2]-usr[1])
~^~
R/addAQIStackedBar.R:23:22: style: Put spaces around all infix operators.
r <- usr[1]+width*(usr[2]-usr[1])
~^~
R/addAQIStackedBar.R:23:23: style: Place a space before left parenthesis, except in a function call.
r <- usr[1]+width*(usr[2]-usr[1])
^
R/addAQIStackedBar.R:23:30: style: Put spaces around all infix operators.
r <- usr[1]+width*(usr[2]-usr[1])
~^~
R/addAQIStackedBar.R:28:20: style: Commas should always have a space after.
min(max(0,AQI$breaks_24[i]), height*usr[4]),
^
R/addAQIStackedBar.R:28:45: style: Put spaces around all infix operators.
min(max(0,AQI$breaks_24[i]), height*usr[4]),
~^~
R/addAQIStackedBar.R:30:29: style: Put spaces around all infix operators.
min(AQI$breaks_24[i+1], height*usr[4]),
~^~
R/addAQIStackedBar.R:30:40: style: Put spaces around all infix operators.
min(AQI$breaks_24[i+1], height*usr[4]),
~^~
R/addBullseye.R:25:63: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex, lwd=lwd, col='black')
~^~
R/addBullseye.R:25:73: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex, lwd=lwd, col='black')
~^~
R/addBullseye.R:25:82: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex, lwd=lwd, col='black')
~^~
R/addBullseye.R:25:91: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex, lwd=lwd, col='black')
~^~
R/addBullseye.R:25:92: style: Only use double-quotes.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex, lwd=lwd, col='black')
^~~~~~~
R/addBullseye.R:26:1: style: Lines should not be more than 100 characters.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.75, lwd=lwd, col='white')
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addBullseye.R:26:63: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:26:73: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:26:77: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:26:87: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:26:96: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:26:97: style: Only use double-quotes.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.75, lwd=lwd, col='white')
^~~~~~~
R/addBullseye.R:27:1: style: Lines should not be more than 100 characters.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.5, lwd=lwd, col='black')
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addBullseye.R:27:63: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:27:73: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:27:77: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:27:86: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:27:95: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:27:96: style: Only use double-quotes.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.5, lwd=lwd, col='black')
^~~~~~~
R/addBullseye.R:31:36: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex, lwd=lwd, col='black')
~^~
R/addBullseye.R:31:43: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex, lwd=lwd, col='black')
~^~
R/addBullseye.R:31:52: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex, lwd=lwd, col='black')
~^~
R/addBullseye.R:31:61: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex, lwd=lwd, col='black')
~^~
R/addBullseye.R:31:62: style: Only use double-quotes.
points(longitude, latitude, pch=1, cex=cex, lwd=lwd, col='black')
^~~~~~~
R/addBullseye.R:32:36: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:32:43: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:32:47: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:32:57: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:32:66: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:32:67: style: Only use double-quotes.
points(longitude, latitude, pch=1, cex=cex*0.75, lwd=lwd, col='white')
^~~~~~~
R/addBullseye.R:33:36: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:33:43: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:33:47: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:33:56: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:33:65: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:33:66: style: Only use double-quotes.
points(longitude, latitude, pch=1, cex=cex*0.5, lwd=lwd, col='black')
^~~~~~~
R/addBullseye.R:38:1: style: Trailing blank lines are superfluous.
^
R/addClustering.R:5:1: style: Lines should not be more than 100 characters.
#' @param tbl tibble with geolocation information (\emph{e.g.} created by \code{wrcc_qualityControl()} or \code{airsis_qualityControl})
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:6:1: style: Lines should not be more than 100 characters.
#' @param clusterDiameter diameter in meters used to determine the number of clusters (see description)
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:13:1: style: Lines should not be more than 100 characters.
#' The value of \code{clusterRadius} is compared with the output of \code{cluster::pam(...)$clusinfo[,'av_diss']}
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:17:1: style: Lines should not be more than 100 characters.
#' @references \href{http://mazamascience.com/WorkingWithData/?p=1694}{When k-means Clustering Fails}
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:31:1: style: Lines should not be more than 100 characters.
logger.error("No lonVar='%s' column found in 'tbl' tibble with columns: %s", lonVar, paste0(names(tbl), collapse=", "))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:31:117: style: Put spaces around all infix operators.
logger.error("No lonVar='%s' column found in 'tbl' tibble with columns: %s", lonVar, paste0(names(tbl), collapse=", "))
~^~
R/addClustering.R:35:1: style: Lines should not be more than 100 characters.
logger.error("No latVar='%s' column found in 'tbl' tibble with columns: %s", latVar, paste0(names(tbl), collapse=", "))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:35:117: style: Put spaces around all infix operators.
logger.error("No latVar='%s' column found in 'tbl' tibble with columns: %s", latVar, paste0(names(tbl), collapse=", "))
~^~
R/addClustering.R:43:46: style: Commas should always have a space after.
lonString <- format( round(tbl$medoidLon,3), nsmall=3 ) # 3 decimal places
^
R/addClustering.R:43:56: style: Put spaces around all infix operators.
lonString <- format( round(tbl$medoidLon,3), nsmall=3 ) # 3 decimal places
~^~
R/addClustering.R:44:46: style: Commas should always have a space after.
latString <- format( round(tbl$medoidLat,3), nsmall=3 ) # 3 decimal places
^
R/addClustering.R:44:56: style: Put spaces around all infix operators.
latString <- format( round(tbl$medoidLat,3), nsmall=3 ) # 3 decimal places
~^~
R/addClustering.R:45:31: style: Only use double-quotes.
locationString <- paste0( 'lon_', lonString, '_lat_', latString )
^~~~~~
R/addClustering.R:45:50: style: Only use double-quotes.
locationString <- paste0( 'lon_', lonString, '_lat_', latString )
^~~~~~~
R/addClustering.R:54:44: style: Commas should always have a space after.
badLocationRows <- tbl[badLocationMask,]
^
R/addClustering.R:55:33: style: Commas should always have a space after.
tbl <- tbl[!badLocationMask,]
^
R/addClustering.R:70:5: style: Commented code should be removed.
# NOTE: x <- y <- c(rep(0,3),rep(1,3),rep(10,20),rep(11,20),rep(100,50),rep(101,50))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:71:5: style: Commented code should be removed.
# NOTE: m <- cbind(x,y)
^~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:72:5: style: Commented code should be removed.
# NOTE: layout(matrix(seq(2)))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:73:5: style: Commented code should be removed.
# NOTE: plot(x, y, pch=as.character( stats::kmeans(m,3)$cluster ))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:74:5: style: Commented code should be removed.
# NOTE: plot(x, y, pch=as.character( cluster::pam(m,3)$cluster ))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:75:5: style: Commented code should be removed.
# NOTE: plot(x, y, pch=as.character( cluster::clara(m,3)$cluster ))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:92:39: style: Commas should always have a space after.
clusterObj <- cluster::pam(tbl[,c(lonVar,latVar)],clusterCount)
^
R/addClustering.R:92:48: style: Commas should always have a space after.
clusterObj <- cluster::pam(tbl[,c(lonVar,latVar)],clusterCount)
^
R/addClustering.R:92:57: style: Commas should always have a space after.
clusterObj <- cluster::pam(tbl[,c(lonVar,latVar)],clusterCount)
^
R/addClustering.R:95:41: style: Commas should always have a space after.
clusterObj <- cluster::clara(tbl[,c(lonVar,latVar)],clusterCount, samples=50)
^
R/addClustering.R:95:50: style: Commas should always have a space after.
clusterObj <- cluster::clara(tbl[,c(lonVar,latVar)],clusterCount, samples=50)
^
R/addClustering.R:95:59: style: Commas should always have a space after.
clusterObj <- cluster::clara(tbl[,c(lonVar,latVar)],clusterCount, samples=50)
^
R/addClustering.R:95:80: style: Put spaces around all infix operators.
clusterObj <- cluster::clara(tbl[,c(lonVar,latVar)],clusterCount, samples=50)
~^~
R/addClustering.R:97:39: style: Commas should always have a space after.
medoidLats <- clusterObj$medoids[,latVar]
^
R/addClustering.R:98:43: style: Commas should always have a space after.
diameters <- 2 * clusterObj$clusinfo[,'max_diss'] # decimal degrees
^
R/addClustering.R:98:43: style: Only use double-quotes.
diameters <- 2 * clusterObj$clusinfo[,'max_diss'] # decimal degrees
^~~~~~~~~~
R/addClustering.R:102:40: style: Put spaces around all infix operators.
radianMedoidLats <- medoidLats * pi/180
~^~
R/addClustering.R:103:54: style: Put spaces around all infix operators.
meters <- diameters * (1 + cos(radianMedoidLats))/2 * 111320
~^~
R/addClustering.R:111:37: style: Commas should always have a space after.
clusterObj <- cluster::pam(tbl[,c(lonVar,latVar)],clusterCount)
^
R/addClustering.R:111:46: style: Commas should always have a space after.
clusterObj <- cluster::pam(tbl[,c(lonVar,latVar)],clusterCount)
^
R/addClustering.R:111:55: style: Commas should always have a space after.
clusterObj <- cluster::pam(tbl[,c(lonVar,latVar)],clusterCount)
^
R/addClustering.R:113:39: style: Commas should always have a space after.
clusterObj <- cluster::clara(tbl[,c(lonVar,latVar)],clusterCount, samples=50)
^
R/addClustering.R:113:48: style: Commas should always have a space after.
clusterObj <- cluster::clara(tbl[,c(lonVar,latVar)],clusterCount, samples=50)
^
R/addClustering.R:113:57: style: Commas should always have a space after.
clusterObj <- cluster::clara(tbl[,c(lonVar,latVar)],clusterCount, samples=50)
^
R/addClustering.R:113:78: style: Put spaces around all infix operators.
clusterObj <- cluster::clara(tbl[,c(lonVar,latVar)],clusterCount, samples=50)
~^~
R/addClustering.R:117:40: style: Commas should always have a space after.
tbl$medoidLon <- clusterObj$medoids[,lonVar][clusterObj$clustering]
^
R/addClustering.R:118:40: style: Commas should always have a space after.
tbl$medoidLat <- clusterObj$medoids[,latVar][clusterObj$clustering]
^
R/addClustering.R:125:44: style: Commas should always have a space after.
lonString <- format( round(tbl$medoidLon,3), nsmall=3 ) # 3 decimal places
^
R/addClustering.R:125:54: style: Put spaces around all infix operators.
lonString <- format( round(tbl$medoidLon,3), nsmall=3 ) # 3 decimal places
~^~
R/addClustering.R:126:44: style: Commas should always have a space after.
latString <- format( round(tbl$medoidLat,3), nsmall=3 ) # 3 decimal places
^
R/addClustering.R:126:54: style: Put spaces around all infix operators.
latString <- format( round(tbl$medoidLat,3), nsmall=3 ) # 3 decimal places
~^~
R/addClustering.R:127:29: style: Only use double-quotes.
locationString <- paste0( 'lon_', lonString, '_lat_', latString )
^~~~~~
R/addClustering.R:127:48: style: Only use double-quotes.
locationString <- paste0( 'lon_', lonString, '_lat_', latString )
^~~~~~~
R/addClustering.R:139:35: style: Commas should always have a space after.
tbl <- tbl[order(tbl$rowID),]
^
R/addEsriAddress.R:6:1: style: Lines should not be more than 100 characters.
#' @param df dataframe with geolocation information (\emph{e.g.} those created by \code{wrcc_qualityControl()} or \code{airsis_qualityControl})
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addEsriAddress.R:9:1: style: Lines should not be more than 100 characters.
#' @param existingMeta existing 'meta' dataframe from which to obtain metadata for known monitor deployments
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addEsriAddress.R:14:1: style: Lines should not be more than 100 characters.
#' @references \url{https://developers.arcgis.com/rest/geocode/api-reference/geocoding-reverse-geocode.htm}
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addEsriAddress.R:26:43: style: Put spaces around all infix operators.
df <- as.data.frame(df, stringsAsFactors=FALSE)
~^~
R/addEsriAddress.R:32:63: style: Commas should always have a space after.
stop(paste0("Dataframe does not contain columns lonVar='",lonVar,"' or latVar='",latVar,"'"))
^
R/addEsriAddress.R:32:70: style: Commas should always have a space after.
stop(paste0("Dataframe does not contain columns lonVar='",lonVar,"' or latVar='",latVar,"'"))
^
R/addEsriAddress.R:32:86: style: Commas should always have a space after.
stop(paste0("Dataframe does not contain columns lonVar='",lonVar,"' or latVar='",latVar,"'"))
^
R/addEsriAddress.R:32:93: style: Commas should always have a space after.
stop(paste0("Dataframe does not contain columns lonVar='",lonVar,"' or latVar='",latVar,"'"))
^
R/addEsriAddress.R:43:1: style: Lines should not be more than 100 characters.
# NOTE: https://geocode.arcgis.com/arcgis/rest/services/World/GeocodeServer/reverseGeocode?outSR=4326&returnIntersection=false&location=-121.06092453002931%2C47.255990221115475&f=json
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addEsriAddress.R:91:23: style: Commas should always have a space after.
monitorID <- df[i,'monitorID']
^
R/addEsriAddress.R:91:23: style: Only use double-quotes.
monitorID <- df[i,'monitorID']
^~~~~~~~~~~
R/addEsriAddress.R:94:1: style: Lines should not be more than 100 characters.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addEsriAddress.R:94:44: style: Commas should always have a space after.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^
R/addEsriAddress.R:94:44: style: Only use double-quotes.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^~~~~~~~~~
R/addEsriAddress.R:94:83: style: Commas should always have a space after.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^
R/addEsriAddress.R:94:83: style: Only use double-quotes.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^~~~~~~~~~
R/addEsriAddress.R:104:48: style: Commas should always have a space after.
df$siteName[i] <- existingMeta[monitorID,'siteName']
^
R/addEsriAddress.R:104:48: style: Only use double-quotes.
df$siteName[i] <- existingMeta[monitorID,'siteName']
^~~~~~~~~~
R/addEsriAddress.R:105:51: style: Only use double-quotes.
df$countyName[i] <- existingMeta[monitorID, 'countyName']
^~~~~~~~~~~~
R/addEsriAddress.R:110:26: style: Commas should always have a space after.
location <- c(df[i,lonVar],df[i,latVar])
^
R/addEsriAddress.R:110:34: style: Commas should always have a space after.
location <- c(df[i,lonVar],df[i,latVar])
^
R/addEsriAddress.R:110:39: style: Commas should always have a space after.
location <- c(df[i,lonVar],df[i,latVar])
^
R/addEsriAddress.R:116:1: style: Lines should not be more than 100 characters.
urlBase <- "https://geocode.arcgis.com/arcgis/rest/services/World/GeocodeServer/reverseGeocode?"
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addEsriAddress.R:117:42: style: Commas should always have a space after.
location <- paste0("location=",paste0(location[1],",",location[2]),"&")
^
R/addEsriAddress.R:117:61: style: Commas should always have a space after.
location <- paste0("location=",paste0(location[1],",",location[2]),"&")
^
R/addEsriAddress.R:117:65: style: Commas should always have a space after.
location <- paste0("location=",paste0(location[1],",",location[2]),"&")
^
R/addEsriAddress.R:117:78: style: Commas should always have a space after.
location <- paste0("location=",paste0(location[1],",",location[2]),"&")
^
R/addEsriAddress.R:143:63: style: Commas should always have a space after.
df$siteName[i] <- paste0(returnObj$address$City,"-",returnObj$address$Address)
^
R/addEsriAddress.R:143:67: style: Commas should always have a space after.
df$siteName[i] <- paste0(returnObj$address$City,"-",returnObj$address$Address)
^
R/addEsriAddress.R:153:82: style: Commas should always have a space after.
df$countyName[i] <- stringr::str_replace(returnObj$address$Subregion,' County','')
^
R/addEsriAddress.R:153:82: style: Only use double-quotes.
df$countyName[i] <- stringr::str_replace(returnObj$address$Subregion,' County','')
^~~~~~~~~
R/addEsriAddress.R:153:92: style: Commas should always have a space after.
df$countyName[i] <- stringr::str_replace(returnObj$address$Subregion,' County','')
^
R/addEsriAddress.R:153:92: style: Only use double-quotes.
df$countyName[i] <- stringr::str_replace(returnObj$address$Subregion,' County','')
^~
R/addEsriAddress.R:156:18: style: Put spaces around all infix operators.
}, silent=TRUE)
~^~
R/addGoogleAddress.R:6:1: style: Lines should not be more than 100 characters.
#' @param df dataframe with geolocation information (\emph{e.g.} those created by \code{wrcc_qualityControl()} or \code{airsis_qualityControl})
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addGoogleAddress.R:9:1: style: Lines should not be more than 100 characters.
#' @param existingMeta existing 'meta' dataframe from which to obtain metadata for known monitor deployments
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addGoogleAddress.R:20:6: style: Commented code should be removed.
###logger.trace(" ----- addGoogleAddress() ----- ")
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addGoogleAddress.R:22:1: style: Lines should not be more than 100 characters.
message("addGoogleAddress() is currently disabled after discontinuation of free querys in July, 2018")
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addGoogleAddress.R:25:43: style: Put spaces around all infix operators.
df <- as.data.frame(df, stringsAsFactors=FALSE)
~^~
R/addGoogleAddress.R:31:63: style: Commas should always have a space after.
stop(paste0("Dataframe does not contain columns lonVar='",lonVar,"' or latVar='",latVar,"'"))
^
R/addGoogleAddress.R:31:70: style: Commas should always have a space after.
stop(paste0("Dataframe does not contain columns lonVar='",lonVar,"' or latVar='",latVar,"'"))
^
R/addGoogleAddress.R:31:86: style: Commas should always have a space after.
stop(paste0("Dataframe does not contain columns lonVar='",lonVar,"' or latVar='",latVar,"'"))
^
R/addGoogleAddress.R:31:93: style: Commas should always have a space after.
stop(paste0("Dataframe does not contain columns lonVar='",lonVar,"' or latVar='",latVar,"'"))
^
R/addGoogleAddress.R:38:3: warning: local variable ‘lons’ assigned but may not be used
lons <- df[[lonVar]]
^~~~
R/addGoogleAddress.R:39:3: warning: local variable ‘lats’ assigned but may not be used
lats <- df[[latVar]]
^~~~
R/addGoogleAddress.R:49:7: style: Only use double-quotes.
if ('ggmap' %in% installed.packages()[,1]) {
^~~~~~~
R/addGoogleAddress.R:49:42: style: Commas should always have a space after.
if ('ggmap' %in% installed.packages()[,1]) {
^
R/addGoogleAddress.R:60:25: style: Commas should always have a space after.
monitorID <- df[i,'monitorID']
^
R/addGoogleAddress.R:60:25: style: Only use double-quotes.
monitorID <- df[i,'monitorID']
^~~~~~~~~~~
R/addGoogleAddress.R:63:1: style: Lines should not be more than 100 characters.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addGoogleAddress.R:63:46: style: Commas should always have a space after.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^
R/addGoogleAddress.R:63:46: style: Only use double-quotes.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^~~~~~~~~~
R/addGoogleAddress.R:63:85: style: Commas should always have a space after.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^
R/addGoogleAddress.R:63:85: style: Only use double-quotes.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^~~~~~~~~~
R/addGoogleAddress.R:73:50: style: Commas should always have a space after.
df$siteName[i] <- existingMeta[monitorID,'siteName']
^
R/addGoogleAddress.R:73:50: style: Only use double-quotes.
df$siteName[i] <- existingMeta[monitorID,'siteName']
^~~~~~~~~~
R/addGoogleAddress.R:74:53: style: Only use double-quotes.
df$countyName[i] <- existingMeta[monitorID, 'countyName']
^~~~~~~~~~~~
R/addGoogleAddress.R:79:28: style: Commas should always have a space after.
location <- c(df[i,lonVar],df[i,latVar])
^
R/addGoogleAddress.R:79:36: style: Commas should always have a space after.
location <- c(df[i,lonVar],df[i,latVar])
^
R/addGoogleAddress.R:79:41: style: Commas should always have a space after.
location <- c(df[i,lonVar],df[i,latVar])
^
R/addGoogleAddress.R:82:74: style: Put spaces around all infix operators.
address <- suppressMessages( ggmap::revgeocode(location, output='more') )
~^~
R/addGoogleAddress.R:82:75: style: Only use double-quotes.
address <- suppressMessages( ggmap::revgeocode(location, output='more') )
^~~~~~
R/addGoogleAddress.R:84:67: style: Commas should always have a space after.
result <- try( df$siteName[i] <- paste(address$locality,address$route,sep='-'),
^
R/addGoogleAddress.R:84:81: style: Commas should always have a space after.
result <- try( df$siteName[i] <- paste(address$locality,address$route,sep='-'),
^
R/addGoogleAddress.R:84:84: style: Put spaces around all infix operators.
result <- try( df$siteName[i] <- paste(address$locality,address$route,sep='-'),
~^~
R/addGoogleAddress.R:84:85: style: Only use double-quotes.
result <- try( df$siteName[i] <- paste(address$locality,address$route,sep='-'),
^~~
R/addGoogleAddress.R:85:32: style: Put spaces around all infix operators.
silent=TRUE ) # don't show errors
~^~
R/addGoogleAddress.R:87:1: style: Lines should not be more than 100 characters.
logger.warn("Google geocoding may have failed. Have you gone over the 2.5K/day limit? (2017)")
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addGoogleAddress.R:90:1: style: Lines should not be more than 100 characters.
try( df$countyName[i] <- stringr::str_replace(address$administrative_area_level_2,' County',''),
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addGoogleAddress.R:90:93: style: Commas should always have a space after.
try( df$countyName[i] <- stringr::str_replace(address$administrative_area_level_2,' County',''),
^
R/addGoogleAddress.R:90:93: style: Only use double-quotes.
try( df$countyName[i] <- stringr::str_replace(address$administrative_area_level_2,' County',''),
^~~~~~~~~
R/addGoogleAddress.R:90:103: style: Commas should always have a space after.
try( df$countyName[i] <- stringr::str_replace(address$administrative_area_level_2,' County',''),
^
R/addGoogleAddress.R:90:103: style: Only use double-quotes.
try( df$countyName[i] <- stringr::str_replace(address$administrative_area_level_2,' County',''),
^~
R/addGoogleAddress.R:91:22: style: Put spaces around all infix operators.
silent=TRUE ) # don't show errors
~^~
R/addGoogleElevation.R:5:1: style: Lines should not be more than 100 characters.
#' @param df dataframe with geolocation information (\emph{e.g.} those created by \code{wrcc_qualityControl()} or \code{airsis_qualityControl})
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addGoogleElevation.R:8:1: style: Lines should not be more than 100 characters.
#' @param existingMeta existing 'meta' dataframe from which to obtain metadata for known monitor deployments
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addAQILegend.R:11:1: style: Lines should not be more than 100 characters.
#' @description This function is a convenience wrapper around \code{graphics::legend()}. It will show the AQI colors and
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addAQILegend.R:11:121: style: Trailing whitespace is superfluous.
#' @description This function is a convenience wrapper around \code{graphics::legend()}. It will show the AQI colors and
^
R/addAQILegend.R:21:1: style: Trailing whitespace is superfluous.
^~
R/addAQILegend.R:22:12: style: Put spaces around all infix operators.
legend( x=x, y=y, col=col, legend=legend, pch=pch, title=title, ... )
~^~
R/addAQILegend.R:22:17: style: Put spaces around all infix operators.
legend( x=x, y=y, col=col, legend=legend, pch=pch, title=title, ... )
~^~
R/addAQILegend.R:22:24: style: Put spaces around all infix operators.
legend( x=x, y=y, col=col, legend=legend, pch=pch, title=title, ... )
~^~
R/addAQILegend.R:22:36: style: Put spaces around all infix operators.
legend( x=x, y=y, col=col, legend=legend, pch=pch, title=title, ... )
~^~
R/addAQILegend.R:22:48: style: Put spaces around all infix operators.
legend( x=x, y=y, col=col, legend=legend, pch=pch, title=title, ... )
~^~
R/addAQILegend.R:22:59: style: Put spaces around all infix operators.
legend( x=x, y=y, col=col, legend=legend, pch=pch, title=title, ... )
~^~
R/addAQILegend.R:23:1: style: Trailing whitespace is superfluous.
^~
R/addAQILines.R:6:3: style: Trailing whitespace is superfluous.
#'
^
R/addAQILines.R:10:1: style: Trailing whitespace is superfluous.
^~
R/addAQILines.R:11:21: style: Put spaces around all infix operators.
graphics::abline(h=AQI$breaks_24, col=AQI$colors, ...)
~^~
R/addAQILines.R:11:40: style: Put spaces around all infix operators.
graphics::abline(h=AQI$breaks_24, col=AQI$colors, ...)
~^~
R/addAQILines.R:12:1: style: Trailing whitespace is superfluous.
^~
R/addAQIStackedBar.R:19:16: style: Put spaces around all infix operators.
l <- usr[2]-width*(usr[2]-usr[1])
~^~
R/addAQIStackedBar.R:19:22: style: Put spaces around all infix operators.
l <- usr[2]-width*(usr[2]-usr[1])
~^~
R/addAQIStackedBar.R:19:23: style: Place a space before left parenthesis, except in a function call.
l <- usr[2]-width*(usr[2]-usr[1])
^
R/addAQIStackedBar.R:19:30: style: Put spaces around all infix operators.
l <- usr[2]-width*(usr[2]-usr[1])
~^~
R/addAQIStackedBar.R:23:16: style: Put spaces around all infix operators.
r <- usr[1]+width*(usr[2]-usr[1])
~^~
R/addAQIStackedBar.R:23:22: style: Put spaces around all infix operators.
r <- usr[1]+width*(usr[2]-usr[1])
~^~
R/addAQIStackedBar.R:23:23: style: Place a space before left parenthesis, except in a function call.
r <- usr[1]+width*(usr[2]-usr[1])
^
R/addAQIStackedBar.R:23:30: style: Put spaces around all infix operators.
r <- usr[1]+width*(usr[2]-usr[1])
~^~
R/addAQIStackedBar.R:28:20: style: Commas should always have a space after.
min(max(0,AQI$breaks_24[i]), height*usr[4]),
^
R/addAQIStackedBar.R:28:45: style: Put spaces around all infix operators.
min(max(0,AQI$breaks_24[i]), height*usr[4]),
~^~
R/addAQIStackedBar.R:30:29: style: Put spaces around all infix operators.
min(AQI$breaks_24[i+1], height*usr[4]),
~^~
R/addAQIStackedBar.R:30:40: style: Put spaces around all infix operators.
min(AQI$breaks_24[i+1], height*usr[4]),
~^~
R/addBullseye.R:25:63: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex, lwd=lwd, col='black')
~^~
R/addBullseye.R:25:73: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex, lwd=lwd, col='black')
~^~
R/addBullseye.R:25:82: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex, lwd=lwd, col='black')
~^~
R/addBullseye.R:25:91: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex, lwd=lwd, col='black')
~^~
R/addBullseye.R:25:92: style: Only use double-quotes.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex, lwd=lwd, col='black')
^~~~~~~
R/addBullseye.R:26:1: style: Lines should not be more than 100 characters.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.75, lwd=lwd, col='white')
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addBullseye.R:26:63: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:26:73: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:26:77: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:26:87: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:26:96: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:26:97: style: Only use double-quotes.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.75, lwd=lwd, col='white')
^~~~~~~
R/addBullseye.R:27:1: style: Lines should not be more than 100 characters.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.5, lwd=lwd, col='black')
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addBullseye.R:27:63: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:27:73: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:27:77: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:27:86: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:27:95: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:27:96: style: Only use double-quotes.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.5, lwd=lwd, col='black')
^~~~~~~
R/addBullseye.R:31:36: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex, lwd=lwd, col='black')
~^~
R/addBullseye.R:31:43: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex, lwd=lwd, col='black')
~^~
R/addBullseye.R:31:52: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex, lwd=lwd, col='black')
~^~
R/addBullseye.R:31:61: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex, lwd=lwd, col='black')
~^~
R/addBullseye.R:31:62: style: Only use double-quotes.
points(longitude, latitude, pch=1, cex=cex, lwd=lwd, col='black')
^~~~~~~
R/addBullseye.R:32:36: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:32:43: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:32:47: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:32:57: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:32:66: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:32:67: style: Only use double-quotes.
points(longitude, latitude, pch=1, cex=cex*0.75, lwd=lwd, col='white')
^~~~~~~
R/addBullseye.R:33:36: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:33:43: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:33:47: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:33:56: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:33:65: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:33:66: style: Only use double-quotes.
points(longitude, latitude, pch=1, cex=cex*0.5, lwd=lwd, col='black')
^~~~~~~
R/addBullseye.R:38:1: style: Trailing blank lines are superfluous.
^
R/addClustering.R:5:1: style: Lines should not be more than 100 characters.
#' @param tbl tibble with geolocation information (\emph{e.g.} created by \code{wrcc_qualityControl()} or \code{airsis_qualityControl})
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:6:1: style: Lines should not be more than 100 characters.
#' @param clusterDiameter diameter in meters used to determine the number of clusters (see description)
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:13:1: style: Lines should not be more than 100 characters.
#' The value of \code{clusterRadius} is compared with the output of \code{cluster::pam(...)$clusinfo[,'av_diss']}
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:17:1: style: Lines should not be more than 100 characters.
#' @references \href{http://mazamascience.com/WorkingWithData/?p=1694}{When k-means Clustering Fails}
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:31:1: style: Lines should not be more than 100 characters.
logger.error("No lonVar='%s' column found in 'tbl' tibble with columns: %s", lonVar, paste0(names(tbl), collapse=", "))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:31:117: style: Put spaces around all infix operators.
logger.error("No lonVar='%s' column found in 'tbl' tibble with columns: %s", lonVar, paste0(names(tbl), collapse=", "))
~^~
R/addClustering.R:35:1: style: Lines should not be more than 100 characters.
logger.error("No latVar='%s' column found in 'tbl' tibble with columns: %s", latVar, paste0(names(tbl), collapse=", "))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:35:117: style: Put spaces around all infix operators.
logger.error("No latVar='%s' column found in 'tbl' tibble with columns: %s", latVar, paste0(names(tbl), collapse=", "))
~^~
R/addClustering.R:43:46: style: Commas should always have a space after.
lonString <- format( round(tbl$medoidLon,3), nsmall=3 ) # 3 decimal places
^
R/addClustering.R:43:56: style: Put spaces around all infix operators.
lonString <- format( round(tbl$medoidLon,3), nsmall=3 ) # 3 decimal places
~^~
R/addClustering.R:44:46: style: Commas should always have a space after.
latString <- format( round(tbl$medoidLat,3), nsmall=3 ) # 3 decimal places
^
R/addClustering.R:44:56: style: Put spaces around all infix operators.
latString <- format( round(tbl$medoidLat,3), nsmall=3 ) # 3 decimal places
~^~
R/addClustering.R:45:31: style: Only use double-quotes.
locationString <- paste0( 'lon_', lonString, '_lat_', latString )
^~~~~~
R/addClustering.R:45:50: style: Only use double-quotes.
locationString <- paste0( 'lon_', lonString, '_lat_', latString )
^~~~~~~
R/addClustering.R:54:44: style: Commas should always have a space after.
badLocationRows <- tbl[badLocationMask,]
^
R/addClustering.R:55:33: style: Commas should always have a space after.
tbl <- tbl[!badLocationMask,]
^
R/addClustering.R:70:5: style: Commented code should be removed.
# NOTE: x <- y <- c(rep(0,3),rep(1,3),rep(10,20),rep(11,20),rep(100,50),rep(101,50))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:71:5: style: Commented code should be removed.
# NOTE: m <- cbind(x,y)
^~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:72:5: style: Commented code should be removed.
# NOTE: layout(matrix(seq(2)))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:73:5: style: Commented code should be removed.
# NOTE: plot(x, y, pch=as.character( stats::kmeans(m,3)$cluster ))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:74:5: style: Commented code should be removed.
# NOTE: plot(x, y, pch=as.character( cluster::pam(m,3)$cluster ))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:75:5: style: Commented code should be removed.
# NOTE: plot(x, y, pch=as.character( cluster::clara(m,3)$cluster ))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:92:39: style: Commas should always have a space after.
clusterObj <- cluster::pam(tbl[,c(lonVar,latVar)],clusterCount)
^
R/addClustering.R:92:48: style: Commas should always have a space after.
clusterObj <- cluster::pam(tbl[,c(lonVar,latVar)],clusterCount)
^
R/addClustering.R:92:57: style: Commas should always have a space after.
clusterObj <- cluster::pam(tbl[,c(lonVar,latVar)],clusterCount)
^
R/addClustering.R:95:41: style: Commas should always have a space after.
clusterObj <- cluster::clara(tbl[,c(lonVar,latVar)],clusterCount, samples=50)
^
R/addClustering.R:95:50: style: Commas should always have a space after.
clusterObj <- cluster::clara(tbl[,c(lonVar,latVar)],clusterCount, samples=50)
^
R/addClustering.R:95:59: style: Commas should always have a space after.
clusterObj <- cluster::clara(tbl[,c(lonVar,latVar)],clusterCount, samples=50)
^
R/addClustering.R:95:80: style: Put spaces around all infix operators.
clusterObj <- cluster::clara(tbl[,c(lonVar,latVar)],clusterCount, samples=50)
~^~
R/addClustering.R:97:39: style: Commas should always have a space after.
medoidLats <- clusterObj$medoids[,latVar]
^
R/addClustering.R:98:43: style: Commas should always have a space after.
diameters <- 2 * clusterObj$clusinfo[,'max_diss'] # decimal degrees
^
R/addClustering.R:98:43: style: Only use double-quotes.
diameters <- 2 * clusterObj$clusinfo[,'max_diss'] # decimal degrees
^~~~~~~~~~
R/addClustering.R:102:40: style: Put spaces around all infix operators.
radianMedoidLats <- medoidLats * pi/180
~^~
R/addClustering.R:103:54: style: Put spaces around all infix operators.
meters <- diameters * (1 + cos(radianMedoidLats))/2 * 111320
~^~
R/addClustering.R:111:37: style: Commas should always have a space after.
clusterObj <- cluster::pam(tbl[,c(lonVar,latVar)],clusterCount)
^
R/addClustering.R:111:46: style: Commas should always have a space after.
clusterObj <- cluster::pam(tbl[,c(lonVar,latVar)],clusterCount)
^
R/addClustering.R:111:55: style: Commas should always have a space after.
clusterObj <- cluster::pam(tbl[,c(lonVar,latVar)],clusterCount)
^
R/addClustering.R:113:39: style: Commas should always have a space after.
clusterObj <- cluster::clara(tbl[,c(lonVar,latVar)],clusterCount, samples=50)
^
R/addClustering.R:113:48: style: Commas should always have a space after.
clusterObj <- cluster::clara(tbl[,c(lonVar,latVar)],clusterCount, samples=50)
^
R/addClustering.R:113:57: style: Commas should always have a space after.
clusterObj <- cluster::clara(tbl[,c(lonVar,latVar)],clusterCount, samples=50)
^
R/addClustering.R:113:78: style: Put spaces around all infix operators.
clusterObj <- cluster::clara(tbl[,c(lonVar,latVar)],clusterCount, samples=50)
~^~
R/addClustering.R:117:40: style: Commas should always have a space after.
tbl$medoidLon <- clusterObj$medoids[,lonVar][clusterObj$clustering]
^
R/addClustering.R:118:40: style: Commas should always have a space after.
tbl$medoidLat <- clusterObj$medoids[,latVar][clusterObj$clustering]
^
R/addClustering.R:125:44: style: Commas should always have a space after.
lonString <- format( round(tbl$medoidLon,3), nsmall=3 ) # 3 decimal places
^
R/addClustering.R:125:54: style: Put spaces around all infix operators.
lonString <- format( round(tbl$medoidLon,3), nsmall=3 ) # 3 decimal places
~^~
R/addClustering.R:126:44: style: Commas should always have a space after.
latString <- format( round(tbl$medoidLat,3), nsmall=3 ) # 3 decimal places
^
R/addClustering.R:126:54: style: Put spaces around all infix operators.
latString <- format( round(tbl$medoidLat,3), nsmall=3 ) # 3 decimal places
~^~
R/addClustering.R:127:29: style: Only use double-quotes.
locationString <- paste0( 'lon_', lonString, '_lat_', latString )
^~~~~~
R/addClustering.R:127:48: style: Only use double-quotes.
locationString <- paste0( 'lon_', lonString, '_lat_', latString )
^~~~~~~
R/addClustering.R:139:35: style: Commas should always have a space after.
tbl <- tbl[order(tbl$rowID),]
^
R/addEsriAddress.R:6:1: style: Lines should not be more than 100 characters.
#' @param df dataframe with geolocation information (\emph{e.g.} those created by \code{wrcc_qualityControl()} or \code{airsis_qualityControl})
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addEsriAddress.R:9:1: style: Lines should not be more than 100 characters.
#' @param existingMeta existing 'meta' dataframe from which to obtain metadata for known monitor deployments
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addEsriAddress.R:14:1: style: Lines should not be more than 100 characters.
#' @references \url{https://developers.arcgis.com/rest/geocode/api-reference/geocoding-reverse-geocode.htm}
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addEsriAddress.R:26:43: style: Put spaces around all infix operators.
df <- as.data.frame(df, stringsAsFactors=FALSE)
~^~
R/addEsriAddress.R:32:63: style: Commas should always have a space after.
stop(paste0("Dataframe does not contain columns lonVar='",lonVar,"' or latVar='",latVar,"'"))
^
R/addEsriAddress.R:32:70: style: Commas should always have a space after.
stop(paste0("Dataframe does not contain columns lonVar='",lonVar,"' or latVar='",latVar,"'"))
^
R/addEsriAddress.R:32:86: style: Commas should always have a space after.
stop(paste0("Dataframe does not contain columns lonVar='",lonVar,"' or latVar='",latVar,"'"))
^
R/addEsriAddress.R:32:93: style: Commas should always have a space after.
stop(paste0("Dataframe does not contain columns lonVar='",lonVar,"' or latVar='",latVar,"'"))
^
R/addEsriAddress.R:43:1: style: Lines should not be more than 100 characters.
# NOTE: https://geocode.arcgis.com/arcgis/rest/services/World/GeocodeServer/reverseGeocode?outSR=4326&returnIntersection=false&location=-121.06092453002931%2C47.255990221115475&f=json
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addEsriAddress.R:91:23: style: Commas should always have a space after.
monitorID <- df[i,'monitorID']
^
R/addEsriAddress.R:91:23: style: Only use double-quotes.
monitorID <- df[i,'monitorID']
^~~~~~~~~~~
R/addEsriAddress.R:94:1: style: Lines should not be more than 100 characters.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addEsriAddress.R:94:44: style: Commas should always have a space after.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^
R/addEsriAddress.R:94:44: style: Only use double-quotes.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^~~~~~~~~~
R/addEsriAddress.R:94:83: style: Commas should always have a space after.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^
R/addEsriAddress.R:94:83: style: Only use double-quotes.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^~~~~~~~~~
R/addEsriAddress.R:104:48: style: Commas should always have a space after.
df$siteName[i] <- existingMeta[monitorID,'siteName']
^
R/addEsriAddress.R:104:48: style: Only use double-quotes.
df$siteName[i] <- existingMeta[monitorID,'siteName']
^~~~~~~~~~
R/addEsriAddress.R:105:51: style: Only use double-quotes.
df$countyName[i] <- existingMeta[monitorID, 'countyName']
^~~~~~~~~~~~
R/addEsriAddress.R:110:26: style: Commas should always have a space after.
location <- c(df[i,lonVar],df[i,latVar])
^
R/addEsriAddress.R:110:34: style: Commas should always have a space after.
location <- c(df[i,lonVar],df[i,latVar])
^
R/addEsriAddress.R:110:39: style: Commas should always have a space after.
location <- c(df[i,lonVar],df[i,latVar])
^
R/addEsriAddress.R:116:1: style: Lines should not be more than 100 characters.
urlBase <- "https://geocode.arcgis.com/arcgis/rest/services/World/GeocodeServer/reverseGeocode?"
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addEsriAddress.R:117:42: style: Commas should always have a space after.
location <- paste0("location=",paste0(location[1],",",location[2]),"&")
^
R/addEsriAddress.R:117:61: style: Commas should always have a space after.
location <- paste0("location=",paste0(location[1],",",location[2]),"&")
^
R/addEsriAddress.R:117:65: style: Commas should always have a space after.
location <- paste0("location=",paste0(location[1],",",location[2]),"&")
^
R/addEsriAddress.R:117:78: style: Commas should always have a space after.
location <- paste0("location=",paste0(location[1],",",location[2]),"&")
^
R/addEsriAddress.R:143:63: style: Commas should always have a space after.
df$siteName[i] <- paste0(returnObj$address$City,"-",returnObj$address$Address)
^
R/addEsriAddress.R:143:67: style: Commas should always have a space after.
df$siteName[i] <- paste0(returnObj$address$City,"-",returnObj$address$Address)
^
R/addEsriAddress.R:153:82: style: Commas should always have a space after.
df$countyName[i] <- stringr::str_replace(returnObj$address$Subregion,' County','')
^
R/addEsriAddress.R:153:82: style: Only use double-quotes.
df$countyName[i] <- stringr::str_replace(returnObj$address$Subregion,' County','')
^~~~~~~~~
R/addEsriAddress.R:153:92: style: Commas should always have a space after.
df$countyName[i] <- stringr::str_replace(returnObj$address$Subregion,' County','')
^
R/addEsriAddress.R:153:92: style: Only use double-quotes.
df$countyName[i] <- stringr::str_replace(returnObj$address$Subregion,' County','')
^~
R/addEsriAddress.R:156:18: style: Put spaces around all infix operators.
}, silent=TRUE)
~^~
R/addGoogleAddress.R:6:1: style: Lines should not be more than 100 characters.
#' @param df dataframe with geolocation information (\emph{e.g.} those created by \code{wrcc_qualityControl()} or \code{airsis_qualityControl})
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addGoogleAddress.R:9:1: style: Lines should not be more than 100 characters.
#' @param existingMeta existing 'meta' dataframe from which to obtain metadata for known monitor deployments
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addGoogleAddress.R:20:6: style: Commented code should be removed.
###logger.trace(" ----- addGoogleAddress() ----- ")
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addGoogleAddress.R:22:1: style: Lines should not be more than 100 characters.
message("addGoogleAddress() is currently disabled after discontinuation of free querys in July, 2018")
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addGoogleAddress.R:25:43: style: Put spaces around all infix operators.
df <- as.data.frame(df, stringsAsFactors=FALSE)
~^~
R/addGoogleAddress.R:31:63: style: Commas should always have a space after.
stop(paste0("Dataframe does not contain columns lonVar='",lonVar,"' or latVar='",latVar,"'"))
^
R/addGoogleAddress.R:31:70: style: Commas should always have a space after.
stop(paste0("Dataframe does not contain columns lonVar='",lonVar,"' or latVar='",latVar,"'"))
^
R/addGoogleAddress.R:31:86: style: Commas should always have a space after.
stop(paste0("Dataframe does not contain columns lonVar='",lonVar,"' or latVar='",latVar,"'"))
^
R/addGoogleAddress.R:31:93: style: Commas should always have a space after.
stop(paste0("Dataframe does not contain columns lonVar='",lonVar,"' or latVar='",latVar,"'"))
^
R/addGoogleAddress.R:38:3: warning: local variable ‘lons’ assigned but may not be used
lons <- df[[lonVar]]
^~~~
R/addGoogleAddress.R:39:3: warning: local variable ‘lats’ assigned but may not be used
lats <- df[[latVar]]
^~~~
R/addGoogleAddress.R:49:7: style: Only use double-quotes.
if ('ggmap' %in% installed.packages()[,1]) {
^~~~~~~
R/addGoogleAddress.R:49:42: style: Commas should always have a space after.
if ('ggmap' %in% installed.packages()[,1]) {
^
R/addGoogleAddress.R:60:25: style: Commas should always have a space after.
monitorID <- df[i,'monitorID']
^
R/addGoogleAddress.R:60:25: style: Only use double-quotes.
monitorID <- df[i,'monitorID']
^~~~~~~~~~~
R/addGoogleAddress.R:63:1: style: Lines should not be more than 100 characters.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addGoogleAddress.R:63:46: style: Commas should always have a space after.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^
R/addGoogleAddress.R:63:46: style: Only use double-quotes.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^~~~~~~~~~
R/addGoogleAddress.R:63:85: style: Commas should always have a space after.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^
R/addGoogleAddress.R:63:85: style: Only use double-quotes.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^~~~~~~~~~
R/addGoogleAddress.R:73:50: style: Commas should always have a space after.
df$siteName[i] <- existingMeta[monitorID,'siteName']
^
R/addGoogleAddress.R:73:50: style: Only use double-quotes.
df$siteName[i] <- existingMeta[monitorID,'siteName']
^~~~~~~~~~
R/addGoogleAddress.R:74:53: style: Only use double-quotes.
df$countyName[i] <- existingMeta[monitorID, 'countyName']
^~~~~~~~~~~~
R/addGoogleAddress.R:79:28: style: Commas should always have a space after.
location <- c(df[i,lonVar],df[i,latVar])
^
R/addGoogleAddress.R:79:36: style: Commas should always have a space after.
location <- c(df[i,lonVar],df[i,latVar])
^
R/addGoogleAddress.R:79:41: style: Commas should always have a space after.
location <- c(df[i,lonVar],df[i,latVar])
^
R/addGoogleAddress.R:82:74: style: Put spaces around all infix operators.
address <- suppressMessages( ggmap::revgeocode(location, output='more') )
~^~
R/addGoogleAddress.R:82:75: style: Only use double-quotes.
address <- suppressMessages( ggmap::revgeocode(location, output='more') )
^~~~~~
R/addGoogleAddress.R:84:67: style: Commas should always have a space after.
result <- try( df$siteName[i] <- paste(address$locality,address$route,sep='-'),
^
R/addGoogleAddress.R:84:81: style: Commas should always have a space after.
result <- try( df$siteName[i] <- paste(address$locality,address$route,sep='-'),
^
R/addGoogleAddress.R:84:84: style: Put spaces around all infix operators.
result <- try( df$siteName[i] <- paste(address$locality,address$route,sep='-'),
~^~
R/addGoogleAddress.R:84:85: style: Only use double-quotes.
result <- try( df$siteName[i] <- paste(address$locality,address$route,sep='-'),
^~~
R/addGoogleAddress.R:85:32: style: Put spaces around all infix operators.
silent=TRUE ) # don't show errors
~^~
R/addGoogleAddress.R:87:1: style: Lines should not be more than 100 characters.
logger.warn("Google geocoding may have failed. Have you gone over the 2.5K/day limit? (2017)")
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addGoogleAddress.R:90:1: style: Lines should not be more than 100 characters.
try( df$countyName[i] <- stringr::str_replace(address$administrative_area_level_2,' County',''),
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addGoogleAddress.R:90:93: style: Commas should always have a space after.
try( df$countyName[i] <- stringr::str_replace(address$administrative_area_level_2,' County',''),
^
R/addGoogleAddress.R:90:93: style: Only use double-quotes.
try( df$countyName[i] <- stringr::str_replace(address$administrative_area_level_2,' County',''),
^~~~~~~~~
R/addGoogleAddress.R:90:103: style: Commas should always have a space after.
try( df$countyName[i] <- stringr::str_replace(address$administrative_area_level_2,' County',''),
^
R/addGoogleAddress.R:90:103: style: Only use double-quotes.
try( df$countyName[i] <- stringr::str_replace(address$administrative_area_level_2,' County',''),
^~
R/addGoogleAddress.R:91:22: style: Put spaces around all infix operators.
silent=TRUE ) # don't show errors
~^~
R/addGoogleElevation.R:5:1: style: Lines should not be more than 100 characters.
#' @param df dataframe with geolocation information (\emph{e.g.} those created by \code{wrcc_qualityControl()} or \code{airsis_qualityControl})
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addGoogleElevation.R:8:1: style: Lines should not be more than 100 characters.
#' @param existingMeta existing 'meta' dataframe from which to obtain metadata for known monitor deployments
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addAQILegend.R:11:1: style: Lines should not be more than 100 characters.
#' @description This function is a convenience wrapper around \code{graphics::legend()}. It will show the AQI colors and
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addAQILegend.R:11:121: style: Trailing whitespace is superfluous.
#' @description This function is a convenience wrapper around \code{graphics::legend()}. It will show the AQI colors and
^
R/addAQILegend.R:21:1: style: Trailing whitespace is superfluous.
^~
R/addAQILegend.R:22:12: style: Put spaces around all infix operators.
legend( x=x, y=y, col=col, legend=legend, pch=pch, title=title, ... )
~^~
R/addAQILegend.R:22:17: style: Put spaces around all infix operators.
legend( x=x, y=y, col=col, legend=legend, pch=pch, title=title, ... )
~^~
R/addAQILegend.R:22:24: style: Put spaces around all infix operators.
legend( x=x, y=y, col=col, legend=legend, pch=pch, title=title, ... )
~^~
R/addAQILegend.R:22:36: style: Put spaces around all infix operators.
legend( x=x, y=y, col=col, legend=legend, pch=pch, title=title, ... )
~^~
R/addAQILegend.R:22:48: style: Put spaces around all infix operators.
legend( x=x, y=y, col=col, legend=legend, pch=pch, title=title, ... )
~^~
R/addAQILegend.R:22:59: style: Put spaces around all infix operators.
legend( x=x, y=y, col=col, legend=legend, pch=pch, title=title, ... )
~^~
R/addAQILegend.R:23:1: style: Trailing whitespace is superfluous.
^~
R/addAQILines.R:6:3: style: Trailing whitespace is superfluous.
#'
^
R/addAQILines.R:10:1: style: Trailing whitespace is superfluous.
^~
R/addAQILines.R:11:21: style: Put spaces around all infix operators.
graphics::abline(h=AQI$breaks_24, col=AQI$colors, ...)
~^~
R/addAQILines.R:11:40: style: Put spaces around all infix operators.
graphics::abline(h=AQI$breaks_24, col=AQI$colors, ...)
~^~
R/addAQILines.R:12:1: style: Trailing whitespace is superfluous.
^~
R/addAQIStackedBar.R:19:16: style: Put spaces around all infix operators.
l <- usr[2]-width*(usr[2]-usr[1])
~^~
R/addAQIStackedBar.R:19:22: style: Put spaces around all infix operators.
l <- usr[2]-width*(usr[2]-usr[1])
~^~
R/addAQIStackedBar.R:19:23: style: Place a space before left parenthesis, except in a function call.
l <- usr[2]-width*(usr[2]-usr[1])
^
R/addAQIStackedBar.R:19:30: style: Put spaces around all infix operators.
l <- usr[2]-width*(usr[2]-usr[1])
~^~
R/addAQIStackedBar.R:23:16: style: Put spaces around all infix operators.
r <- usr[1]+width*(usr[2]-usr[1])
~^~
R/addAQIStackedBar.R:23:22: style: Put spaces around all infix operators.
r <- usr[1]+width*(usr[2]-usr[1])
~^~
R/addAQIStackedBar.R:23:23: style: Place a space before left parenthesis, except in a function call.
r <- usr[1]+width*(usr[2]-usr[1])
^
R/addAQIStackedBar.R:23:30: style: Put spaces around all infix operators.
r <- usr[1]+width*(usr[2]-usr[1])
~^~
R/addAQIStackedBar.R:28:20: style: Commas should always have a space after.
min(max(0,AQI$breaks_24[i]), height*usr[4]),
^
R/addAQIStackedBar.R:28:45: style: Put spaces around all infix operators.
min(max(0,AQI$breaks_24[i]), height*usr[4]),
~^~
R/addAQIStackedBar.R:30:29: style: Put spaces around all infix operators.
min(AQI$breaks_24[i+1], height*usr[4]),
~^~
R/addAQIStackedBar.R:30:40: style: Put spaces around all infix operators.
min(AQI$breaks_24[i+1], height*usr[4]),
~^~
R/addBullseye.R:25:63: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex, lwd=lwd, col='black')
~^~
R/addBullseye.R:25:73: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex, lwd=lwd, col='black')
~^~
R/addBullseye.R:25:82: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex, lwd=lwd, col='black')
~^~
R/addBullseye.R:25:91: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex, lwd=lwd, col='black')
~^~
R/addBullseye.R:25:92: style: Only use double-quotes.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex, lwd=lwd, col='black')
^~~~~~~
R/addBullseye.R:26:1: style: Lines should not be more than 100 characters.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.75, lwd=lwd, col='white')
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addBullseye.R:26:63: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:26:73: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:26:77: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:26:87: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:26:96: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:26:97: style: Only use double-quotes.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.75, lwd=lwd, col='white')
^~~~~~~
R/addBullseye.R:27:1: style: Lines should not be more than 100 characters.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.5, lwd=lwd, col='black')
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addBullseye.R:27:63: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:27:73: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:27:77: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:27:86: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:27:95: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:27:96: style: Only use double-quotes.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.5, lwd=lwd, col='black')
^~~~~~~
R/addBullseye.R:31:36: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex, lwd=lwd, col='black')
~^~
R/addBullseye.R:31:43: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex, lwd=lwd, col='black')
~^~
R/addBullseye.R:31:52: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex, lwd=lwd, col='black')
~^~
R/addBullseye.R:31:61: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex, lwd=lwd, col='black')
~^~
R/addBullseye.R:31:62: style: Only use double-quotes.
points(longitude, latitude, pch=1, cex=cex, lwd=lwd, col='black')
^~~~~~~
R/addBullseye.R:32:36: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:32:43: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:32:47: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:32:57: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:32:66: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:32:67: style: Only use double-quotes.
points(longitude, latitude, pch=1, cex=cex*0.75, lwd=lwd, col='white')
^~~~~~~
R/addBullseye.R:33:36: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:33:43: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:33:47: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:33:56: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:33:65: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:33:66: style: Only use double-quotes.
points(longitude, latitude, pch=1, cex=cex*0.5, lwd=lwd, col='black')
^~~~~~~
R/addBullseye.R:38:1: style: Trailing blank lines are superfluous.
^
R/addClustering.R:5:1: style: Lines should not be more than 100 characters.
#' @param tbl tibble with geolocation information (\emph{e.g.} created by \code{wrcc_qualityControl()} or \code{airsis_qualityControl})
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:6:1: style: Lines should not be more than 100 characters.
#' @param clusterDiameter diameter in meters used to determine the number of clusters (see description)
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:13:1: style: Lines should not be more than 100 characters.
#' The value of \code{clusterRadius} is compared with the output of \code{cluster::pam(...)$clusinfo[,'av_diss']}
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:17:1: style: Lines should not be more than 100 characters.
#' @references \href{http://mazamascience.com/WorkingWithData/?p=1694}{When k-means Clustering Fails}
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:31:1: style: Lines should not be more than 100 characters.
logger.error("No lonVar='%s' column found in 'tbl' tibble with columns: %s", lonVar, paste0(names(tbl), collapse=", "))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:31:117: style: Put spaces around all infix operators.
logger.error("No lonVar='%s' column found in 'tbl' tibble with columns: %s", lonVar, paste0(names(tbl), collapse=", "))
~^~
R/addClustering.R:35:1: style: Lines should not be more than 100 characters.
logger.error("No latVar='%s' column found in 'tbl' tibble with columns: %s", latVar, paste0(names(tbl), collapse=", "))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:35:117: style: Put spaces around all infix operators.
logger.error("No latVar='%s' column found in 'tbl' tibble with columns: %s", latVar, paste0(names(tbl), collapse=", "))
~^~
R/addClustering.R:43:46: style: Commas should always have a space after.
lonString <- format( round(tbl$medoidLon,3), nsmall=3 ) # 3 decimal places
^
R/addClustering.R:43:56: style: Put spaces around all infix operators.
lonString <- format( round(tbl$medoidLon,3), nsmall=3 ) # 3 decimal places
~^~
R/addClustering.R:44:46: style: Commas should always have a space after.
latString <- format( round(tbl$medoidLat,3), nsmall=3 ) # 3 decimal places
^
R/addClustering.R:44:56: style: Put spaces around all infix operators.
latString <- format( round(tbl$medoidLat,3), nsmall=3 ) # 3 decimal places
~^~
R/addClustering.R:45:31: style: Only use double-quotes.
locationString <- paste0( 'lon_', lonString, '_lat_', latString )
^~~~~~
R/addClustering.R:45:50: style: Only use double-quotes.
locationString <- paste0( 'lon_', lonString, '_lat_', latString )
^~~~~~~
R/addClustering.R:54:44: style: Commas should always have a space after.
badLocationRows <- tbl[badLocationMask,]
^
R/addClustering.R:55:33: style: Commas should always have a space after.
tbl <- tbl[!badLocationMask,]
^
R/addClustering.R:70:5: style: Commented code should be removed.
# NOTE: x <- y <- c(rep(0,3),rep(1,3),rep(10,20),rep(11,20),rep(100,50),rep(101,50))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:71:5: style: Commented code should be removed.
# NOTE: m <- cbind(x,y)
^~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:72:5: style: Commented code should be removed.
# NOTE: layout(matrix(seq(2)))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:73:5: style: Commented code should be removed.
# NOTE: plot(x, y, pch=as.character( stats::kmeans(m,3)$cluster ))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:74:5: style: Commented code should be removed.
# NOTE: plot(x, y, pch=as.character( cluster::pam(m,3)$cluster ))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:75:5: style: Commented code should be removed.
# NOTE: plot(x, y, pch=as.character( cluster::clara(m,3)$cluster ))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:92:39: style: Commas should always have a space after.
clusterObj <- cluster::pam(tbl[,c(lonVar,latVar)],clusterCount)
^
R/addClustering.R:92:48: style: Commas should always have a space after.
clusterObj <- cluster::pam(tbl[,c(lonVar,latVar)],clusterCount)
^
R/addClustering.R:92:57: style: Commas should always have a space after.
clusterObj <- cluster::pam(tbl[,c(lonVar,latVar)],clusterCount)
^
R/addClustering.R:95:41: style: Commas should always have a space after.
clusterObj <- cluster::clara(tbl[,c(lonVar,latVar)],clusterCount, samples=50)
^
R/addClustering.R:95:50: style: Commas should always have a space after.
clusterObj <- cluster::clara(tbl[,c(lonVar,latVar)],clusterCount, samples=50)
^
R/addClustering.R:95:59: style: Commas should always have a space after.
clusterObj <- cluster::clara(tbl[,c(lonVar,latVar)],clusterCount, samples=50)
^
R/addClustering.R:95:80: style: Put spaces around all infix operators.
clusterObj <- cluster::clara(tbl[,c(lonVar,latVar)],clusterCount, samples=50)
~^~
R/addClustering.R:97:39: style: Commas should always have a space after.
medoidLats <- clusterObj$medoids[,latVar]
^
R/addClustering.R:98:43: style: Commas should always have a space after.
diameters <- 2 * clusterObj$clusinfo[,'max_diss'] # decimal degrees
^
R/addClustering.R:98:43: style: Only use double-quotes.
diameters <- 2 * clusterObj$clusinfo[,'max_diss'] # decimal degrees
^~~~~~~~~~
R/addClustering.R:102:40: style: Put spaces around all infix operators.
radianMedoidLats <- medoidLats * pi/180
~^~
R/addClustering.R:103:54: style: Put spaces around all infix operators.
meters <- diameters * (1 + cos(radianMedoidLats))/2 * 111320
~^~
R/addClustering.R:111:37: style: Commas should always have a space after.
clusterObj <- cluster::pam(tbl[,c(lonVar,latVar)],clusterCount)
^
R/addClustering.R:111:46: style: Commas should always have a space after.
clusterObj <- cluster::pam(tbl[,c(lonVar,latVar)],clusterCount)
^
R/addClustering.R:111:55: style: Commas should always have a space after.
clusterObj <- cluster::pam(tbl[,c(lonVar,latVar)],clusterCount)
^
R/addClustering.R:113:39: style: Commas should always have a space after.
clusterObj <- cluster::clara(tbl[,c(lonVar,latVar)],clusterCount, samples=50)
^
R/addClustering.R:113:48: style: Commas should always have a space after.
clusterObj <- cluster::clara(tbl[,c(lonVar,latVar)],clusterCount, samples=50)
^
R/addClustering.R:113:57: style: Commas should always have a space after.
clusterObj <- cluster::clara(tbl[,c(lonVar,latVar)],clusterCount, samples=50)
^
R/addClustering.R:113:78: style: Put spaces around all infix operators.
clusterObj <- cluster::clara(tbl[,c(lonVar,latVar)],clusterCount, samples=50)
~^~
R/addClustering.R:117:40: style: Commas should always have a space after.
tbl$medoidLon <- clusterObj$medoids[,lonVar][clusterObj$clustering]
^
R/addClustering.R:118:40: style: Commas should always have a space after.
tbl$medoidLat <- clusterObj$medoids[,latVar][clusterObj$clustering]
^
R/addClustering.R:125:44: style: Commas should always have a space after.
lonString <- format( round(tbl$medoidLon,3), nsmall=3 ) # 3 decimal places
^
R/addClustering.R:125:54: style: Put spaces around all infix operators.
lonString <- format( round(tbl$medoidLon,3), nsmall=3 ) # 3 decimal places
~^~
R/addClustering.R:126:44: style: Commas should always have a space after.
latString <- format( round(tbl$medoidLat,3), nsmall=3 ) # 3 decimal places
^
R/addClustering.R:126:54: style: Put spaces around all infix operators.
latString <- format( round(tbl$medoidLat,3), nsmall=3 ) # 3 decimal places
~^~
R/addClustering.R:127:29: style: Only use double-quotes.
locationString <- paste0( 'lon_', lonString, '_lat_', latString )
^~~~~~
R/addClustering.R:127:48: style: Only use double-quotes.
locationString <- paste0( 'lon_', lonString, '_lat_', latString )
^~~~~~~
R/addClustering.R:139:35: style: Commas should always have a space after.
tbl <- tbl[order(tbl$rowID),]
^
R/addEsriAddress.R:6:1: style: Lines should not be more than 100 characters.
#' @param df dataframe with geolocation information (\emph{e.g.} those created by \code{wrcc_qualityControl()} or \code{airsis_qualityControl})
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addEsriAddress.R:9:1: style: Lines should not be more than 100 characters.
#' @param existingMeta existing 'meta' dataframe from which to obtain metadata for known monitor deployments
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addEsriAddress.R:14:1: style: Lines should not be more than 100 characters.
#' @references \url{https://developers.arcgis.com/rest/geocode/api-reference/geocoding-reverse-geocode.htm}
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addEsriAddress.R:26:43: style: Put spaces around all infix operators.
df <- as.data.frame(df, stringsAsFactors=FALSE)
~^~
R/addEsriAddress.R:32:63: style: Commas should always have a space after.
stop(paste0("Dataframe does not contain columns lonVar='",lonVar,"' or latVar='",latVar,"'"))
^
R/addEsriAddress.R:32:70: style: Commas should always have a space after.
stop(paste0("Dataframe does not contain columns lonVar='",lonVar,"' or latVar='",latVar,"'"))
^
R/addEsriAddress.R:32:86: style: Commas should always have a space after.
stop(paste0("Dataframe does not contain columns lonVar='",lonVar,"' or latVar='",latVar,"'"))
^
R/addEsriAddress.R:32:93: style: Commas should always have a space after.
stop(paste0("Dataframe does not contain columns lonVar='",lonVar,"' or latVar='",latVar,"'"))
^
R/addEsriAddress.R:43:1: style: Lines should not be more than 100 characters.
# NOTE: https://geocode.arcgis.com/arcgis/rest/services/World/GeocodeServer/reverseGeocode?outSR=4326&returnIntersection=false&location=-121.06092453002931%2C47.255990221115475&f=json
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addEsriAddress.R:91:23: style: Commas should always have a space after.
monitorID <- df[i,'monitorID']
^
R/addEsriAddress.R:91:23: style: Only use double-quotes.
monitorID <- df[i,'monitorID']
^~~~~~~~~~~
R/addEsriAddress.R:94:1: style: Lines should not be more than 100 characters.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addEsriAddress.R:94:44: style: Commas should always have a space after.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^
R/addEsriAddress.R:94:44: style: Only use double-quotes.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^~~~~~~~~~
R/addEsriAddress.R:94:83: style: Commas should always have a space after.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^
R/addEsriAddress.R:94:83: style: Only use double-quotes.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^~~~~~~~~~
R/addEsriAddress.R:104:48: style: Commas should always have a space after.
df$siteName[i] <- existingMeta[monitorID,'siteName']
^
R/addEsriAddress.R:104:48: style: Only use double-quotes.
df$siteName[i] <- existingMeta[monitorID,'siteName']
^~~~~~~~~~
R/addEsriAddress.R:105:51: style: Only use double-quotes.
df$countyName[i] <- existingMeta[monitorID, 'countyName']
^~~~~~~~~~~~
R/addEsriAddress.R:110:26: style: Commas should always have a space after.
location <- c(df[i,lonVar],df[i,latVar])
^
R/addEsriAddress.R:110:34: style: Commas should always have a space after.
location <- c(df[i,lonVar],df[i,latVar])
^
R/addEsriAddress.R:110:39: style: Commas should always have a space after.
location <- c(df[i,lonVar],df[i,latVar])
^
R/addEsriAddress.R:116:1: style: Lines should not be more than 100 characters.
urlBase <- "https://geocode.arcgis.com/arcgis/rest/services/World/GeocodeServer/reverseGeocode?"
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addEsriAddress.R:117:42: style: Commas should always have a space after.
location <- paste0("location=",paste0(location[1],",",location[2]),"&")
^
R/addEsriAddress.R:117:61: style: Commas should always have a space after.
location <- paste0("location=",paste0(location[1],",",location[2]),"&")
^
R/addEsriAddress.R:117:65: style: Commas should always have a space after.
location <- paste0("location=",paste0(location[1],",",location[2]),"&")
^
R/addEsriAddress.R:117:78: style: Commas should always have a space after.
location <- paste0("location=",paste0(location[1],",",location[2]),"&")
^
R/addEsriAddress.R:143:63: style: Commas should always have a space after.
df$siteName[i] <- paste0(returnObj$address$City,"-",returnObj$address$Address)
^
R/addEsriAddress.R:143:67: style: Commas should always have a space after.
df$siteName[i] <- paste0(returnObj$address$City,"-",returnObj$address$Address)
^
R/addEsriAddress.R:153:82: style: Commas should always have a space after.
df$countyName[i] <- stringr::str_replace(returnObj$address$Subregion,' County','')
^
R/addEsriAddress.R:153:82: style: Only use double-quotes.
df$countyName[i] <- stringr::str_replace(returnObj$address$Subregion,' County','')
^~~~~~~~~
R/addEsriAddress.R:153:92: style: Commas should always have a space after.
df$countyName[i] <- stringr::str_replace(returnObj$address$Subregion,' County','')
^
R/addEsriAddress.R:153:92: style: Only use double-quotes.
df$countyName[i] <- stringr::str_replace(returnObj$address$Subregion,' County','')
^~
R/addEsriAddress.R:156:18: style: Put spaces around all infix operators.
}, silent=TRUE)
~^~
R/addGoogleAddress.R:6:1: style: Lines should not be more than 100 characters.
#' @param df dataframe with geolocation information (\emph{e.g.} those created by \code{wrcc_qualityControl()} or \code{airsis_qualityControl})
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addGoogleAddress.R:9:1: style: Lines should not be more than 100 characters.
#' @param existingMeta existing 'meta' dataframe from which to obtain metadata for known monitor deployments
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addGoogleAddress.R:20:6: style: Commented code should be removed.
###logger.trace(" ----- addGoogleAddress() ----- ")
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addGoogleAddress.R:22:1: style: Lines should not be more than 100 characters.
message("addGoogleAddress() is currently disabled after discontinuation of free querys in July, 2018")
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addGoogleAddress.R:25:43: style: Put spaces around all infix operators.
df <- as.data.frame(df, stringsAsFactors=FALSE)
~^~
R/addGoogleAddress.R:31:63: style: Commas should always have a space after.
stop(paste0("Dataframe does not contain columns lonVar='",lonVar,"' or latVar='",latVar,"'"))
^
R/addGoogleAddress.R:31:70: style: Commas should always have a space after.
stop(paste0("Dataframe does not contain columns lonVar='",lonVar,"' or latVar='",latVar,"'"))
^
R/addGoogleAddress.R:31:86: style: Commas should always have a space after.
stop(paste0("Dataframe does not contain columns lonVar='",lonVar,"' or latVar='",latVar,"'"))
^
R/addGoogleAddress.R:31:93: style: Commas should always have a space after.
stop(paste0("Dataframe does not contain columns lonVar='",lonVar,"' or latVar='",latVar,"'"))
^
R/addGoogleAddress.R:38:3: warning: local variable ‘lons’ assigned but may not be used
lons <- df[[lonVar]]
^~~~
R/addGoogleAddress.R:39:3: warning: local variable ‘lats’ assigned but may not be used
lats <- df[[latVar]]
^~~~
R/addGoogleAddress.R:49:7: style: Only use double-quotes.
if ('ggmap' %in% installed.packages()[,1]) {
^~~~~~~
R/addGoogleAddress.R:49:42: style: Commas should always have a space after.
if ('ggmap' %in% installed.packages()[,1]) {
^
R/addGoogleAddress.R:60:25: style: Commas should always have a space after.
monitorID <- df[i,'monitorID']
^
R/addGoogleAddress.R:60:25: style: Only use double-quotes.
monitorID <- df[i,'monitorID']
^~~~~~~~~~~
R/addGoogleAddress.R:63:1: style: Lines should not be more than 100 characters.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addGoogleAddress.R:63:46: style: Commas should always have a space after.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^
R/addGoogleAddress.R:63:46: style: Only use double-quotes.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^~~~~~~~~~
R/addGoogleAddress.R:63:85: style: Commas should always have a space after.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^
R/addGoogleAddress.R:63:85: style: Only use double-quotes.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^~~~~~~~~~
R/addGoogleAddress.R:73:50: style: Commas should always have a space after.
df$siteName[i] <- existingMeta[monitorID,'siteName']
^
R/addGoogleAddress.R:73:50: style: Only use double-quotes.
df$siteName[i] <- existingMeta[monitorID,'siteName']
^~~~~~~~~~
R/addGoogleAddress.R:74:53: style: Only use double-quotes.
df$countyName[i] <- existingMeta[monitorID, 'countyName']
^~~~~~~~~~~~
R/addGoogleAddress.R:79:28: style: Commas should always have a space after.
location <- c(df[i,lonVar],df[i,latVar])
^
R/addGoogleAddress.R:79:36: style: Commas should always have a space after.
location <- c(df[i,lonVar],df[i,latVar])
^
R/addGoogleAddress.R:79:41: style: Commas should always have a space after.
location <- c(df[i,lonVar],df[i,latVar])
^
R/addGoogleAddress.R:82:74: style: Put spaces around all infix operators.
address <- suppressMessages( ggmap::revgeocode(location, output='more') )
~^~
R/addGoogleAddress.R:82:75: style: Only use double-quotes.
address <- suppressMessages( ggmap::revgeocode(location, output='more') )
^~~~~~
R/addGoogleAddress.R:84:67: style: Commas should always have a space after.
result <- try( df$siteName[i] <- paste(address$locality,address$route,sep='-'),
^
R/addGoogleAddress.R:84:81: style: Commas should always have a space after.
result <- try( df$siteName[i] <- paste(address$locality,address$route,sep='-'),
^
R/addGoogleAddress.R:84:84: style: Put spaces around all infix operators.
result <- try( df$siteName[i] <- paste(address$locality,address$route,sep='-'),
~^~
R/addGoogleAddress.R:84:85: style: Only use double-quotes.
result <- try( df$siteName[i] <- paste(address$locality,address$route,sep='-'),
^~~
R/addGoogleAddress.R:85:32: style: Put spaces around all infix operators.
silent=TRUE ) # don't show errors
~^~
R/addGoogleAddress.R:87:1: style: Lines should not be more than 100 characters.
logger.warn("Google geocoding may have failed. Have you gone over the 2.5K/day limit? (2017)")
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addGoogleAddress.R:90:1: style: Lines should not be more than 100 characters.
try( df$countyName[i] <- stringr::str_replace(address$administrative_area_level_2,' County',''),
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addGoogleAddress.R:90:93: style: Commas should always have a space after.
try( df$countyName[i] <- stringr::str_replace(address$administrative_area_level_2,' County',''),
^
R/addGoogleAddress.R:90:93: style: Only use double-quotes.
try( df$countyName[i] <- stringr::str_replace(address$administrative_area_level_2,' County',''),
^~~~~~~~~
R/addGoogleAddress.R:90:103: style: Commas should always have a space after.
try( df$countyName[i] <- stringr::str_replace(address$administrative_area_level_2,' County',''),
^
R/addGoogleAddress.R:90:103: style: Only use double-quotes.
try( df$countyName[i] <- stringr::str_replace(address$administrative_area_level_2,' County',''),
^~
R/addGoogleAddress.R:91:22: style: Put spaces around all infix operators.
silent=TRUE ) # don't show errors
~^~
R/addGoogleElevation.R:5:1: style: Lines should not be more than 100 characters.
#' @param df dataframe with geolocation information (\emph{e.g.} those created by \code{wrcc_qualityControl()} or \code{airsis_qualityControl})
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addGoogleElevation.R:8:1: style: Lines should not be more than 100 characters.
#' @param existingMeta existing 'meta' dataframe from which to obtain metadata for known monitor deployments
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addAQILegend.R:11:1: style: Lines should not be more than 100 characters.
#' @description This function is a convenience wrapper around \code{graphics::legend()}. It will show the AQI colors and
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addAQILegend.R:11:121: style: Trailing whitespace is superfluous.
#' @description This function is a convenience wrapper around \code{graphics::legend()}. It will show the AQI colors and
^
R/addAQILegend.R:21:1: style: Trailing whitespace is superfluous.
^~
R/addAQILegend.R:22:12: style: Put spaces around all infix operators.
legend( x=x, y=y, col=col, legend=legend, pch=pch, title=title, ... )
~^~
R/addAQILegend.R:22:17: style: Put spaces around all infix operators.
legend( x=x, y=y, col=col, legend=legend, pch=pch, title=title, ... )
~^~
R/addAQILegend.R:22:24: style: Put spaces around all infix operators.
legend( x=x, y=y, col=col, legend=legend, pch=pch, title=title, ... )
~^~
R/addAQILegend.R:22:36: style: Put spaces around all infix operators.
legend( x=x, y=y, col=col, legend=legend, pch=pch, title=title, ... )
~^~
R/addAQILegend.R:22:48: style: Put spaces around all infix operators.
legend( x=x, y=y, col=col, legend=legend, pch=pch, title=title, ... )
~^~
R/addAQILegend.R:22:59: style: Put spaces around all infix operators.
legend( x=x, y=y, col=col, legend=legend, pch=pch, title=title, ... )
~^~
R/addAQILegend.R:23:1: style: Trailing whitespace is superfluous.
^~
R/addAQILines.R:6:3: style: Trailing whitespace is superfluous.
#'
^
R/addAQILines.R:10:1: style: Trailing whitespace is superfluous.
^~
R/addAQILines.R:11:21: style: Put spaces around all infix operators.
graphics::abline(h=AQI$breaks_24, col=AQI$colors, ...)
~^~
R/addAQILines.R:11:40: style: Put spaces around all infix operators.
graphics::abline(h=AQI$breaks_24, col=AQI$colors, ...)
~^~
R/addAQILines.R:12:1: style: Trailing whitespace is superfluous.
^~
R/addAQIStackedBar.R:19:16: style: Put spaces around all infix operators.
l <- usr[2]-width*(usr[2]-usr[1])
~^~
R/addAQIStackedBar.R:19:22: style: Put spaces around all infix operators.
l <- usr[2]-width*(usr[2]-usr[1])
~^~
R/addAQIStackedBar.R:19:23: style: Place a space before left parenthesis, except in a function call.
l <- usr[2]-width*(usr[2]-usr[1])
^
R/addAQIStackedBar.R:19:30: style: Put spaces around all infix operators.
l <- usr[2]-width*(usr[2]-usr[1])
~^~
R/addAQIStackedBar.R:23:16: style: Put spaces around all infix operators.
r <- usr[1]+width*(usr[2]-usr[1])
~^~
R/addAQIStackedBar.R:23:22: style: Put spaces around all infix operators.
r <- usr[1]+width*(usr[2]-usr[1])
~^~
R/addAQIStackedBar.R:23:23: style: Place a space before left parenthesis, except in a function call.
r <- usr[1]+width*(usr[2]-usr[1])
^
R/addAQIStackedBar.R:23:30: style: Put spaces around all infix operators.
r <- usr[1]+width*(usr[2]-usr[1])
~^~
R/addAQIStackedBar.R:28:20: style: Commas should always have a space after.
min(max(0,AQI$breaks_24[i]), height*usr[4]),
^
R/addAQIStackedBar.R:28:45: style: Put spaces around all infix operators.
min(max(0,AQI$breaks_24[i]), height*usr[4]),
~^~
R/addAQIStackedBar.R:30:29: style: Put spaces around all infix operators.
min(AQI$breaks_24[i+1], height*usr[4]),
~^~
R/addAQIStackedBar.R:30:40: style: Put spaces around all infix operators.
min(AQI$breaks_24[i+1], height*usr[4]),
~^~
R/addBullseye.R:25:63: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex, lwd=lwd, col='black')
~^~
R/addBullseye.R:25:73: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex, lwd=lwd, col='black')
~^~
R/addBullseye.R:25:82: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex, lwd=lwd, col='black')
~^~
R/addBullseye.R:25:91: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex, lwd=lwd, col='black')
~^~
R/addBullseye.R:25:92: style: Only use double-quotes.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex, lwd=lwd, col='black')
^~~~~~~
R/addBullseye.R:26:1: style: Lines should not be more than 100 characters.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.75, lwd=lwd, col='white')
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addBullseye.R:26:63: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:26:73: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:26:77: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:26:87: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:26:96: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:26:97: style: Only use double-quotes.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.75, lwd=lwd, col='white')
^~~~~~~
R/addBullseye.R:27:1: style: Lines should not be more than 100 characters.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.5, lwd=lwd, col='black')
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addBullseye.R:27:63: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:27:73: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:27:77: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:27:86: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:27:95: style: Put spaces around all infix operators.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:27:96: style: Only use double-quotes.
RgoogleMaps::PlotOnStaticMap(map, latitude, longitude, add=TRUE, cex=cex*0.5, lwd=lwd, col='black')
^~~~~~~
R/addBullseye.R:31:36: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex, lwd=lwd, col='black')
~^~
R/addBullseye.R:31:43: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex, lwd=lwd, col='black')
~^~
R/addBullseye.R:31:52: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex, lwd=lwd, col='black')
~^~
R/addBullseye.R:31:61: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex, lwd=lwd, col='black')
~^~
R/addBullseye.R:31:62: style: Only use double-quotes.
points(longitude, latitude, pch=1, cex=cex, lwd=lwd, col='black')
^~~~~~~
R/addBullseye.R:32:36: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:32:43: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:32:47: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:32:57: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:32:66: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.75, lwd=lwd, col='white')
~^~
R/addBullseye.R:32:67: style: Only use double-quotes.
points(longitude, latitude, pch=1, cex=cex*0.75, lwd=lwd, col='white')
^~~~~~~
R/addBullseye.R:33:36: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:33:43: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:33:47: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:33:56: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:33:65: style: Put spaces around all infix operators.
points(longitude, latitude, pch=1, cex=cex*0.5, lwd=lwd, col='black')
~^~
R/addBullseye.R:33:66: style: Only use double-quotes.
points(longitude, latitude, pch=1, cex=cex*0.5, lwd=lwd, col='black')
^~~~~~~
R/addBullseye.R:38:1: style: Trailing blank lines are superfluous.
^
R/addClustering.R:5:1: style: Lines should not be more than 100 characters.
#' @param tbl tibble with geolocation information (\emph{e.g.} created by \code{wrcc_qualityControl()} or \code{airsis_qualityControl})
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:6:1: style: Lines should not be more than 100 characters.
#' @param clusterDiameter diameter in meters used to determine the number of clusters (see description)
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:13:1: style: Lines should not be more than 100 characters.
#' The value of \code{clusterRadius} is compared with the output of \code{cluster::pam(...)$clusinfo[,'av_diss']}
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:17:1: style: Lines should not be more than 100 characters.
#' @references \href{http://mazamascience.com/WorkingWithData/?p=1694}{When k-means Clustering Fails}
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:31:1: style: Lines should not be more than 100 characters.
logger.error("No lonVar='%s' column found in 'tbl' tibble with columns: %s", lonVar, paste0(names(tbl), collapse=", "))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:31:117: style: Put spaces around all infix operators.
logger.error("No lonVar='%s' column found in 'tbl' tibble with columns: %s", lonVar, paste0(names(tbl), collapse=", "))
~^~
R/addClustering.R:35:1: style: Lines should not be more than 100 characters.
logger.error("No latVar='%s' column found in 'tbl' tibble with columns: %s", latVar, paste0(names(tbl), collapse=", "))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:35:117: style: Put spaces around all infix operators.
logger.error("No latVar='%s' column found in 'tbl' tibble with columns: %s", latVar, paste0(names(tbl), collapse=", "))
~^~
R/addClustering.R:43:46: style: Commas should always have a space after.
lonString <- format( round(tbl$medoidLon,3), nsmall=3 ) # 3 decimal places
^
R/addClustering.R:43:56: style: Put spaces around all infix operators.
lonString <- format( round(tbl$medoidLon,3), nsmall=3 ) # 3 decimal places
~^~
R/addClustering.R:44:46: style: Commas should always have a space after.
latString <- format( round(tbl$medoidLat,3), nsmall=3 ) # 3 decimal places
^
R/addClustering.R:44:56: style: Put spaces around all infix operators.
latString <- format( round(tbl$medoidLat,3), nsmall=3 ) # 3 decimal places
~^~
R/addClustering.R:45:31: style: Only use double-quotes.
locationString <- paste0( 'lon_', lonString, '_lat_', latString )
^~~~~~
R/addClustering.R:45:50: style: Only use double-quotes.
locationString <- paste0( 'lon_', lonString, '_lat_', latString )
^~~~~~~
R/addClustering.R:54:44: style: Commas should always have a space after.
badLocationRows <- tbl[badLocationMask,]
^
R/addClustering.R:55:33: style: Commas should always have a space after.
tbl <- tbl[!badLocationMask,]
^
R/addClustering.R:70:5: style: Commented code should be removed.
# NOTE: x <- y <- c(rep(0,3),rep(1,3),rep(10,20),rep(11,20),rep(100,50),rep(101,50))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:71:5: style: Commented code should be removed.
# NOTE: m <- cbind(x,y)
^~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:72:5: style: Commented code should be removed.
# NOTE: layout(matrix(seq(2)))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:73:5: style: Commented code should be removed.
# NOTE: plot(x, y, pch=as.character( stats::kmeans(m,3)$cluster ))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:74:5: style: Commented code should be removed.
# NOTE: plot(x, y, pch=as.character( cluster::pam(m,3)$cluster ))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:75:5: style: Commented code should be removed.
# NOTE: plot(x, y, pch=as.character( cluster::clara(m,3)$cluster ))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addClustering.R:92:39: style: Commas should always have a space after.
clusterObj <- cluster::pam(tbl[,c(lonVar,latVar)],clusterCount)
^
R/addClustering.R:92:48: style: Commas should always have a space after.
clusterObj <- cluster::pam(tbl[,c(lonVar,latVar)],clusterCount)
^
R/addClustering.R:92:57: style: Commas should always have a space after.
clusterObj <- cluster::pam(tbl[,c(lonVar,latVar)],clusterCount)
^
R/addClustering.R:95:41: style: Commas should always have a space after.
clusterObj <- cluster::clara(tbl[,c(lonVar,latVar)],clusterCount, samples=50)
^
R/addClustering.R:95:50: style: Commas should always have a space after.
clusterObj <- cluster::clara(tbl[,c(lonVar,latVar)],clusterCount, samples=50)
^
R/addClustering.R:95:59: style: Commas should always have a space after.
clusterObj <- cluster::clara(tbl[,c(lonVar,latVar)],clusterCount, samples=50)
^
R/addClustering.R:95:80: style: Put spaces around all infix operators.
clusterObj <- cluster::clara(tbl[,c(lonVar,latVar)],clusterCount, samples=50)
~^~
R/addClustering.R:97:39: style: Commas should always have a space after.
medoidLats <- clusterObj$medoids[,latVar]
^
R/addClustering.R:98:43: style: Commas should always have a space after.
diameters <- 2 * clusterObj$clusinfo[,'max_diss'] # decimal degrees
^
R/addClustering.R:98:43: style: Only use double-quotes.
diameters <- 2 * clusterObj$clusinfo[,'max_diss'] # decimal degrees
^~~~~~~~~~
R/addClustering.R:102:40: style: Put spaces around all infix operators.
radianMedoidLats <- medoidLats * pi/180
~^~
R/addClustering.R:103:54: style: Put spaces around all infix operators.
meters <- diameters * (1 + cos(radianMedoidLats))/2 * 111320
~^~
R/addClustering.R:111:37: style: Commas should always have a space after.
clusterObj <- cluster::pam(tbl[,c(lonVar,latVar)],clusterCount)
^
R/addClustering.R:111:46: style: Commas should always have a space after.
clusterObj <- cluster::pam(tbl[,c(lonVar,latVar)],clusterCount)
^
R/addClustering.R:111:55: style: Commas should always have a space after.
clusterObj <- cluster::pam(tbl[,c(lonVar,latVar)],clusterCount)
^
R/addClustering.R:113:39: style: Commas should always have a space after.
clusterObj <- cluster::clara(tbl[,c(lonVar,latVar)],clusterCount, samples=50)
^
R/addClustering.R:113:48: style: Commas should always have a space after.
clusterObj <- cluster::clara(tbl[,c(lonVar,latVar)],clusterCount, samples=50)
^
R/addClustering.R:113:57: style: Commas should always have a space after.
clusterObj <- cluster::clara(tbl[,c(lonVar,latVar)],clusterCount, samples=50)
^
R/addClustering.R:113:78: style: Put spaces around all infix operators.
clusterObj <- cluster::clara(tbl[,c(lonVar,latVar)],clusterCount, samples=50)
~^~
R/addClustering.R:117:40: style: Commas should always have a space after.
tbl$medoidLon <- clusterObj$medoids[,lonVar][clusterObj$clustering]
^
R/addClustering.R:118:40: style: Commas should always have a space after.
tbl$medoidLat <- clusterObj$medoids[,latVar][clusterObj$clustering]
^
R/addClustering.R:125:44: style: Commas should always have a space after.
lonString <- format( round(tbl$medoidLon,3), nsmall=3 ) # 3 decimal places
^
R/addClustering.R:125:54: style: Put spaces around all infix operators.
lonString <- format( round(tbl$medoidLon,3), nsmall=3 ) # 3 decimal places
~^~
R/addClustering.R:126:44: style: Commas should always have a space after.
latString <- format( round(tbl$medoidLat,3), nsmall=3 ) # 3 decimal places
^
R/addClustering.R:126:54: style: Put spaces around all infix operators.
latString <- format( round(tbl$medoidLat,3), nsmall=3 ) # 3 decimal places
~^~
R/addClustering.R:127:29: style: Only use double-quotes.
locationString <- paste0( 'lon_', lonString, '_lat_', latString )
^~~~~~
R/addClustering.R:127:48: style: Only use double-quotes.
locationString <- paste0( 'lon_', lonString, '_lat_', latString )
^~~~~~~
R/addClustering.R:139:35: style: Commas should always have a space after.
tbl <- tbl[order(tbl$rowID),]
^
R/addEsriAddress.R:6:1: style: Lines should not be more than 100 characters.
#' @param df dataframe with geolocation information (\emph{e.g.} those created by \code{wrcc_qualityControl()} or \code{airsis_qualityControl})
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addEsriAddress.R:9:1: style: Lines should not be more than 100 characters.
#' @param existingMeta existing 'meta' dataframe from which to obtain metadata for known monitor deployments
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addEsriAddress.R:14:1: style: Lines should not be more than 100 characters.
#' @references \url{https://developers.arcgis.com/rest/geocode/api-reference/geocoding-reverse-geocode.htm}
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addEsriAddress.R:26:43: style: Put spaces around all infix operators.
df <- as.data.frame(df, stringsAsFactors=FALSE)
~^~
R/addEsriAddress.R:32:63: style: Commas should always have a space after.
stop(paste0("Dataframe does not contain columns lonVar='",lonVar,"' or latVar='",latVar,"'"))
^
R/addEsriAddress.R:32:70: style: Commas should always have a space after.
stop(paste0("Dataframe does not contain columns lonVar='",lonVar,"' or latVar='",latVar,"'"))
^
R/addEsriAddress.R:32:86: style: Commas should always have a space after.
stop(paste0("Dataframe does not contain columns lonVar='",lonVar,"' or latVar='",latVar,"'"))
^
R/addEsriAddress.R:32:93: style: Commas should always have a space after.
stop(paste0("Dataframe does not contain columns lonVar='",lonVar,"' or latVar='",latVar,"'"))
^
R/addEsriAddress.R:43:1: style: Lines should not be more than 100 characters.
# NOTE: https://geocode.arcgis.com/arcgis/rest/services/World/GeocodeServer/reverseGeocode?outSR=4326&returnIntersection=false&location=-121.06092453002931%2C47.255990221115475&f=json
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addEsriAddress.R:91:23: style: Commas should always have a space after.
monitorID <- df[i,'monitorID']
^
R/addEsriAddress.R:91:23: style: Only use double-quotes.
monitorID <- df[i,'monitorID']
^~~~~~~~~~~
R/addEsriAddress.R:94:1: style: Lines should not be more than 100 characters.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addEsriAddress.R:94:44: style: Commas should always have a space after.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^
R/addEsriAddress.R:94:44: style: Only use double-quotes.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^~~~~~~~~~
R/addEsriAddress.R:94:83: style: Commas should always have a space after.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^
R/addEsriAddress.R:94:83: style: Only use double-quotes.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^~~~~~~~~~
R/addEsriAddress.R:104:48: style: Commas should always have a space after.
df$siteName[i] <- existingMeta[monitorID,'siteName']
^
R/addEsriAddress.R:104:48: style: Only use double-quotes.
df$siteName[i] <- existingMeta[monitorID,'siteName']
^~~~~~~~~~
R/addEsriAddress.R:105:51: style: Only use double-quotes.
df$countyName[i] <- existingMeta[monitorID, 'countyName']
^~~~~~~~~~~~
R/addEsriAddress.R:110:26: style: Commas should always have a space after.
location <- c(df[i,lonVar],df[i,latVar])
^
R/addEsriAddress.R:110:34: style: Commas should always have a space after.
location <- c(df[i,lonVar],df[i,latVar])
^
R/addEsriAddress.R:110:39: style: Commas should always have a space after.
location <- c(df[i,lonVar],df[i,latVar])
^
R/addEsriAddress.R:116:1: style: Lines should not be more than 100 characters.
urlBase <- "https://geocode.arcgis.com/arcgis/rest/services/World/GeocodeServer/reverseGeocode?"
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addEsriAddress.R:117:42: style: Commas should always have a space after.
location <- paste0("location=",paste0(location[1],",",location[2]),"&")
^
R/addEsriAddress.R:117:61: style: Commas should always have a space after.
location <- paste0("location=",paste0(location[1],",",location[2]),"&")
^
R/addEsriAddress.R:117:65: style: Commas should always have a space after.
location <- paste0("location=",paste0(location[1],",",location[2]),"&")
^
R/addEsriAddress.R:117:78: style: Commas should always have a space after.
location <- paste0("location=",paste0(location[1],",",location[2]),"&")
^
R/addEsriAddress.R:143:63: style: Commas should always have a space after.
df$siteName[i] <- paste0(returnObj$address$City,"-",returnObj$address$Address)
^
R/addEsriAddress.R:143:67: style: Commas should always have a space after.
df$siteName[i] <- paste0(returnObj$address$City,"-",returnObj$address$Address)
^
R/addEsriAddress.R:153:82: style: Commas should always have a space after.
df$countyName[i] <- stringr::str_replace(returnObj$address$Subregion,' County','')
^
R/addEsriAddress.R:153:82: style: Only use double-quotes.
df$countyName[i] <- stringr::str_replace(returnObj$address$Subregion,' County','')
^~~~~~~~~
R/addEsriAddress.R:153:92: style: Commas should always have a space after.
df$countyName[i] <- stringr::str_replace(returnObj$address$Subregion,' County','')
^
R/addEsriAddress.R:153:92: style: Only use double-quotes.
df$countyName[i] <- stringr::str_replace(returnObj$address$Subregion,' County','')
^~
R/addEsriAddress.R:156:18: style: Put spaces around all infix operators.
}, silent=TRUE)
~^~
R/addGoogleAddress.R:6:1: style: Lines should not be more than 100 characters.
#' @param df dataframe with geolocation information (\emph{e.g.} those created by \code{wrcc_qualityControl()} or \code{airsis_qualityControl})
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addGoogleAddress.R:9:1: style: Lines should not be more than 100 characters.
#' @param existingMeta existing 'meta' dataframe from which to obtain metadata for known monitor deployments
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addGoogleAddress.R:20:6: style: Commented code should be removed.
###logger.trace(" ----- addGoogleAddress() ----- ")
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addGoogleAddress.R:22:1: style: Lines should not be more than 100 characters.
message("addGoogleAddress() is currently disabled after discontinuation of free querys in July, 2018")
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addGoogleAddress.R:25:43: style: Put spaces around all infix operators.
df <- as.data.frame(df, stringsAsFactors=FALSE)
~^~
R/addGoogleAddress.R:31:63: style: Commas should always have a space after.
stop(paste0("Dataframe does not contain columns lonVar='",lonVar,"' or latVar='",latVar,"'"))
^
R/addGoogleAddress.R:31:70: style: Commas should always have a space after.
stop(paste0("Dataframe does not contain columns lonVar='",lonVar,"' or latVar='",latVar,"'"))
^
R/addGoogleAddress.R:31:86: style: Commas should always have a space after.
stop(paste0("Dataframe does not contain columns lonVar='",lonVar,"' or latVar='",latVar,"'"))
^
R/addGoogleAddress.R:31:93: style: Commas should always have a space after.
stop(paste0("Dataframe does not contain columns lonVar='",lonVar,"' or latVar='",latVar,"'"))
^
R/addGoogleAddress.R:38:3: warning: local variable ‘lons’ assigned but may not be used
lons <- df[[lonVar]]
^~~~
R/addGoogleAddress.R:39:3: warning: local variable ‘lats’ assigned but may not be used
lats <- df[[latVar]]
^~~~
R/addGoogleAddress.R:49:7: style: Only use double-quotes.
if ('ggmap' %in% installed.packages()[,1]) {
^~~~~~~
R/addGoogleAddress.R:49:42: style: Commas should always have a space after.
if ('ggmap' %in% installed.packages()[,1]) {
^
R/addGoogleAddress.R:60:25: style: Commas should always have a space after.
monitorID <- df[i,'monitorID']
^
R/addGoogleAddress.R:60:25: style: Only use double-quotes.
monitorID <- df[i,'monitorID']
^~~~~~~~~~~
R/addGoogleAddress.R:63:1: style: Lines should not be more than 100 characters.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addGoogleAddress.R:63:46: style: Commas should always have a space after.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^
R/addGoogleAddress.R:63:46: style: Only use double-quotes.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^~~~~~~~~~
R/addGoogleAddress.R:63:85: style: Commas should always have a space after.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^
R/addGoogleAddress.R:63:85: style: Only use double-quotes.
if ( !is.na(existingMeta[monitorID,'siteName']) && existingMeta[monitorID,'siteName'] != "" ) {
^~~~~~~~~~
R/addGoogleAddress.R:73:50: style: Commas should always have a space after.
df$siteName[i] <- existingMeta[monitorID,'siteName']
^
R/addGoogleAddress.R:73:50: style: Only use double-quotes.
df$siteName[i] <- existingMeta[monitorID,'siteName']
^~~~~~~~~~
R/addGoogleAddress.R:74:53: style: Only use double-quotes.
df$countyName[i] <- existingMeta[monitorID, 'countyName']
^~~~~~~~~~~~
R/addGoogleAddress.R:79:28: style: Commas should always have a space after.
location <- c(df[i,lonVar],df[i,latVar])
^
R/addGoogleAddress.R:79:36: style: Commas should always have a space after.
location <- c(df[i,lonVar],df[i,latVar])
^
R/addGoogleAddress.R:79:41: style: Commas should always have a space after.
location <- c(df[i,lonVar],df[i,latVar])
^
R/addGoogleAddress.R:82:74: style: Put spaces around all infix operators.
address <- suppressMessages( ggmap::revgeocode(location, output='more') )
~^~
R/addGoogleAddress.R:82:75: style: Only use double-quotes.
address <- suppressMessages( ggmap::revgeocode(location, output='more') )
^~~~~~
R/addGoogleAddress.R:84:67: style: Commas should always have a space after.
result <- try( df$siteName[i] <- paste(address$locality,address$route,sep='-'),
^
R/addGoogleAddress.R:84:81: style: Commas should always have a space after.
result <- try( df$siteName[i] <- paste(address$locality,address$route,sep='-'),
^
R/addGoogleAddress.R:84:84: style: Put spaces around all infix operators.
result <- try( df$siteName[i] <- paste(address$locality,address$route,sep='-'),
~^~
R/addGoogleAddress.R:84:85: style: Only use double-quotes.
result <- try( df$siteName[i] <- paste(address$locality,address$route,sep='-'),
^~~
R/addGoogleAddress.R:85:32: style: Put spaces around all infix operators.
silent=TRUE ) # don't show errors
~^~
R/addGoogleAddress.R:87:1: style: Lines should not be more than 100 characters.
logger.warn("Google geocoding may have failed. Have you gone over the 2.5K/day limit? (2017)")
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addGoogleAddress.R:90:1: style: Lines should not be more than 100 characters.
try( df$countyName[i] <- stringr::str_replace(address$administrative_area_level_2,' County',''),
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addGoogleAddress.R:90:93: style: Commas should always have a space after.
try( df$countyName[i] <- stringr::str_replace(address$administrative_area_level_2,' County',''),
^
R/addGoogleAddress.R:90:93: style: Only use double-quotes.
try( df$countyName[i] <- stringr::str_replace(address$administrative_area_level_2,' County',''),
^~~~~~~~~
R/addGoogleAddress.R:90:103: style: Commas should always have a space after.
try( df$countyName[i] <- stringr::str_replace(address$administrative_area_level_2,' County',''),
^
R/addGoogleAddress.R:90:103: style: Only use double-quotes.
try( df$countyName[i] <- stringr::str_replace(address$administrative_area_level_2,' County',''),
^~
R/addGoogleAddress.R:91:22: style: Put spaces around all infix operators.
silent=TRUE ) # don't show errors
~^~
R/addGoogleElevation.R:5:1: style: Lines should not be more than 100 characters.
#' @param df dataframe with geolocation information (\emph{e.g.} those created by \code{wrcc_qualityControl()} or \code{airsis_qualityControl})
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
R/addGoogleElevation.R:8:1: style: Lines should not be more than 100 characters.
#' @param existingMeta existing 'meta' dataframe from which to obtain metadata for known monitor deployments
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
This release adds functions for working with generic data.
New Functions
generic_downloadData()
generic_parseData()
New notebooks
A notebook Working with Generic Data (in
/localNotebooks
) was created to example the methodology of working with generic data. An example is given, as well as a more thorough explanation of the "configuration list". This is still a work in progress.This closes #50, closes #59