sourcing scripts

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

sourcing scripts

Ahmed M. El-Kenawy
Hi
 
I am extensively using R to process large amount of data. I tried to source my scripts to run sequentially in R, instead of running them seperately. However, I always receive an error message related to the memory size although I upgraded my RAM from 8GB to 16GB. i do not think this is the main problem. This is simply because when I import a script using (open script) and run it, it works. But, when I try to source this script (even only one script), i receive the same message
Error in memory.size(min = TRUE) : unused argument (min = TRUE)

By the way, my script simply looks like:


memory.size(max=TRUE)
memory.limit()
gc()
memory.limit(16000)
memory.size()
gc()
rm(list=ls(all=TRUE))
source("H:\\HIRAM\\Script_1.R")


cheers

Ahmed Kenawy
______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
Reply | Threaded
Open this post in threaded view
|

Re: sourcing scripts

barry rowlingson
On Wed, Jan 29, 2014 at 9:26 AM, Ahmed M. El-Kenawy <[hidden email]> wrote:

> Error in memory.size(min = TRUE) : unused argument (min = TRUE)

 It looks like you've simply typed 'min=TRUE' instead of 'max=TRUE'
somewhere! Somewhere other than the code you sent in the message,
which had max=TRUE. Must be in one of the other scripts sourced in.

Barry

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
Reply | Threaded
Open this post in threaded view
|

FW: sourcing scripts

Ahmed M. El-Kenawy
Hi Barry,

Thanks for your reply. Actually, I tried both max=TRUE and min=TRUE. Neither of them works.

Ahmed Kenawy
________________________________________
From: [hidden email] [[hidden email]] On Behalf Of Barry Rowlingson [[hidden email]]
Sent: Wednesday, January 29, 2014 12:10 PM
To: Ahmed M. El-Kenawy
Cc: [hidden email]
Subject: Re: [R] sourcing scripts

On Wed, Jan 29, 2014 at 9:26 AM, Ahmed M. El-Kenawy <[hidden email]> wrote:

> Error in memory.size(min = TRUE) : unused argument (min = TRUE)

 It looks like you've simply typed 'min=TRUE' instead of 'max=TRUE'
somewhere! Somewhere other than the code you sent in the message,
which had max=TRUE. Must be in one of the other scripts sourced in.

Barry

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
Reply | Threaded
Open this post in threaded view
|

Re: sourcing scripts

Ahmed M. El-Kenawy
In reply to this post by barry rowlingson
Hi Barry,

I removed the lines related to memory size from other scripts and kept it only in the master script. Now it works.

Cheers
Ahmed Kenawy
________________________________________
From: [hidden email] [[hidden email]] On Behalf Of Barry Rowlingson [[hidden email]]
Sent: Wednesday, January 29, 2014 12:10 PM
To: Ahmed M. El-Kenawy
Cc: [hidden email]
Subject: Re: [R] sourcing scripts

On Wed, Jan 29, 2014 at 9:26 AM, Ahmed M. El-Kenawy <[hidden email]> wrote:

> Error in memory.size(min = TRUE) : unused argument (min = TRUE)

 It looks like you've simply typed 'min=TRUE' instead of 'max=TRUE'
somewhere! Somewhere other than the code you sent in the message,
which had max=TRUE. Must be in one of the other scripts sourced in.

Barry

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.