Re: [R] R CMD check says no visible binding for global variable

2025-01-29 Thread Jorgen Harmse via R-help
[R] R CMD check says no visible binding for global variable Message-ID: Content-Type: text/plain; charset="utf-8" I have written a function which returns an SQL query result as a data.frame. Each column of data.frame is a variable not explicitly defined. For every column na

Re: [R] R CMD check says no visible binding for global variable

2025-01-28 Thread Naresh Gurbuxani
e are ways to set it conditionally and save the previous value and > restore it after but this gets to be lots more work ... > > > -Original Message- > From: R-help On Behalf Of Naresh Gurbuxani > Sent: Tuesday, January 28, 2025 4:25 PM > To: Duncan Murdoch > Cc: r-hel

Re: [R] R CMD check says no visible binding for global variable

2025-01-28 Thread Uwe Ligges
-help On Behalf Of Naresh Gurbuxani Sent: Tuesday, January 28, 2025 4:25 PM To: Duncan Murdoch Cc: r-help@r-project.org Subject: Re: [R] R CMD check says no visible binding for global variable This solution worked. Thanks Sent from my iPhone On Jan 28, 2025, at 3:09 PM, Duncan Murdoch wrote:

Re: [R] R CMD check says no visible binding for global variable

2025-01-28 Thread avi.e.gross
restore it after but this gets to be lots more work ... -Original Message- From: R-help On Behalf Of Naresh Gurbuxani Sent: Tuesday, January 28, 2025 4:25 PM To: Duncan Murdoch Cc: r-help@r-project.org Subject: Re: [R] R CMD check says no visible binding for global variable This solution

Re: [R] R CMD check says no visible binding for global variable

2025-01-28 Thread avi.e.gross
I wrote. From: Naresh Gurbuxani Sent: Tuesday, January 28, 2025 1:56 PM To: John Sorkin Cc: avi.e.gr...@gmail.com; r-help@r-project.org Subject: Re: [R] R CMD check says no visible binding for global variable Data.frame is returned by SQL query. It does have column names.

Re: [R] R CMD check says no visible binding for global variable

2025-01-28 Thread Naresh Gurbuxani
o0ukef> >> ____________ >> From: R-help on behalf of >> avi.e.gr...@gmail.com >> Sent: Tuesday, January 28, 2025 12:01:25 AM >> To: 'Naresh Gurbuxani' ; r-help@r-project.org >> >> Subject: Re: [R] R CMD check says no v

Re: [R] R CMD check says no visible binding for global variable

2025-01-28 Thread Duncan Murdoch
_ From: R-help on behalf of avi.e.gr...@gmail.com Sent: Tuesday, January 28, 2025 12:01:25 AM To: 'Naresh Gurbuxani' ; r-help@r-project.org Subject: Re: [R] R CMD check says no visible binding for global variable Naresh, I am not sure how you are creating you

Re: [R] R CMD check says no visible binding for global variable

2025-01-28 Thread Naresh Gurbuxani
___ From: R-help on behalf of avi.e.gr...@gmail.com Sent: Tuesday, January 28, 2025 12:01:25 AM To: 'Naresh Gurbuxani' ; r-help@r-project.org Subject: Re: [R] R CMD check says no visible binding for global variable Naresh, I am not sure how you are creating your data.frame so it

Re: [R] R CMD check says no visible binding for global variable

2025-01-27 Thread Sorkin, John
> colnames(mydata) <- paste0("temp", 1:ncol(mydata)) > mydata temp1 temp2 temp3 1 1 2 3 -Original Message----- From: R-help On Behalf Of Naresh Gurbuxani Sent: Monday, January 27, 2025 5:46 PM To: r-help@r-project.org Subject: [R] R CMD check says no visible

Re: [R] R CMD check says no visible binding for global variable

2025-01-27 Thread avi.e.gross
gt; mydata temp1 temp2 temp3 1 1 2 3 -Original Message- From: R-help On Behalf Of Naresh Gurbuxani Sent: Monday, January 27, 2025 5:46 PM To: r-help@r-project.org Subject: [R] R CMD check says no visible binding for global variable I have written a function which returns a

Re: [R] R CMD check says no visible binding for global variable

2025-01-27 Thread Ben Bolker
This might be better for r-package-de...@r-project.org (since you're asking a question about package-checking). This is a common problem when using non-standard evaluation. Typically you can either use `utils::globalVariables` or set these variables to NULL near the top of your function.

[R] R CMD check says no visible binding for global variable

2025-01-27 Thread Naresh Gurbuxani
I have written a function which returns an SQL query result as a data.frame. Each column of data.frame is a variable not explicitly defined. For every column name, R CMD check says ‘no visible binding for global variable . Status: 1 NOTE Is it possible to tell R CMD check that these variables