I'm curious about a warning coming from the use of package sqldf. I opened
a file and read it using a SQLite select statement:
f =
"/Users/ronaldbarry/Desktop/Three-Dee/LakeMichDepth.txt"> sql_statement = "select long,lat,depth,(lat - 41.62) as templat, (long
+
> 88) as templong
> from file
> where (abs(templat - 0.1*round(templat/0.1,0)) < 0.01)and(abs(templong -
> 0.15*round(templong/0.15,0)) < 0.01)"
> Mich_depth = sqldf::read.csv.sql(file=f,sql >
sql_statement,header=TRUE,sep=' ')
Which ran perfectly well, but it threw a warning:
Warning messages:
1: In stopifnot(is.list(hooks)) :
closing unused connection 6
(/Users/ronaldbarry/Desktop/Three-Dee/LakeMichDepth.txt)
2: In stopifnot(is.list(hooks)) :
closing unused connection 5
(/Users/ronaldbarry/Desktop/Three-Dee/LakeMichDepth.txt)
It looks like it would be good practice to close the connection in code,
but I don't see any function in sqldf
to do so. Is there a way to nicely close the connection, or should I just
ignore the warning? Operating
system is Mac OSX 13.16 High Sierra, R Studio version 1.1.146, R version
3.5.0. Thanks for any info.
On Thu, Aug 16, 2018 at 12:00 PM, Ronald Barry <rpbarry at alaska.edu>
wrote:
> Hi,
> Thanks for all your help. The problem with an error involving
> validspamobject() has been resolved, as a new version of spdep (0.7-7) was
> just released and it seems to have stopped using the deprecated function.
>
> Ron B.
>
[[alternative HTML version deleted]]