Displaying 20 results from an estimated 8000 matches similar to: "command option for R CMD BATCH"
2007 Jan 24
1
writing R shell scripts?
Hi All,
Another newbie question. I want to write an R script that takes
argument from command line and runs and produces output to stdin.
For example if there is file foo.R with following in it.
args = commandArgs()
print(args)
then, when I run it like
$ R foo.R hello
it should print 'hello' on the terminal.
I searched the mainling list and found a very old post that said said
that
2010 Mar 03
2
Rmpi on CentOS (64bit)
I got Rmpi to compile with little difficulty, but had a tricky time
setting the LD_LIBRARY_PATH to use the OpenMPI libs. I now get a
different error when I try to load Rmpi
> require(Rmpi)
Loading required package: Rmpi
librdmacm: couldn't read ABI version.
librdmacm: assuming: 4
libibverbs: Fatal: couldn't read uverbs ABI version.
CMA: unable to open
2006 Jul 31
1
How does biplot.princomp scale its axes?
I'm attempting to modify how biplot draws its red vectors (among other
things). This is how I've started:
Biplot <- function(xx, comps = c(1, 2), cex = c(.6, .4))
{
## Purpose: Makes a biplot with princomp() object to not show arrows
## ----------------------------------------------------------------------
## Arguments: xx is an object made using princomp()
##
2006 Jun 10
2
Regex engine types
> version
_
platform x86_64-unknown-linux-gnu
arch x86_64
os linux-gnu
system x86_64, linux-gnu
status
major 2
minor 2.1
year 2005
month 12
day 20
svn rev
2007 Apr 16
2
Dealing with data frame column names beginning with a numeric
I wish to set up a simple function using boxplot so that it will be
available to someone using R for Windows. (I myself use Linux.)
The way the data is organised makes it convenient to use the boxplot
function in a manner similar to this example given in the help.
> mat <- cbind(Uni05 = (1:100)/21, Norm = rnorm(100),
+ T5 = rt(100, df = 5), Gam2 = rgamma(100, shape
2007 Apr 01
2
commandArgs usage and --args invokation
Dear R experts:
I am a bit stymied by how the argument picking-off works in R batch file usage.
$ cat commandArgs.R
cat(" Command Line Arguments were ", commandArgs(), "\n");
$ /usr/bin/R CMD BATCH commandArgs.R --args 1 2 3
$ /usr/bin/R --args 1 CMD BATCH commandArgs.R
... I am now getting into interactive mode ?! I guess it really is skipping the
rest of the command line
2010 Mar 11
1
Append to outfile in R CMD BATCH mode
Is there a way to append to the outfile when using R CMD BATCH? My code, right now, is:
R CMD BATCH --slave --vanilla '--args place .2 -.1 .9 .6' StratificationSimulation example.output
Everything else is working the way I'd like it. The first few lines of code of my script file are:
options(echo=FALSE)
cmd_args = commandArgs()
print (cmd_args)
#d <-
2007 Aug 01
2
passing args to R CMD BATCH in win 2000
Hello and sorry to bother.
Please help.
I searched the archives but could not find out why --args is being ignored
on Windows 2000.
I try
R CMD BATCH --slave 11.R 11.Rout --args "12"
and 11.R has
x=commandArgs(trail=T)
print(x)
a=x[length(x)]
write.csv(a,file="13.out")
q("no")
the argument is not passed to the R process.
11.Rout only shows processing time and
2004 May 29
1
multiple nesting levels in GEE
Hello,
I'm actually trying to fit a gee model with 2 nesting levels since I expect a
correlation between all members of a litter at a first level and between all
individuals sharing a mother at a second superior level with an exchangeable
matrix. I order my dataframe by both mother and litter
I try several syntaxes:
id= mother*litter which give the same correlation matrix as id=
2002 Jun 21
1
lme: anova vs. intervals
Windows 2000 (v.5.00.2195), R 1.5.1
I have an lme object, fm0, which I examine with anova() and intervals().
The anova output indicates one of the interaction terms is significant, but
the intervals output shows that the single parameter for that term includes
0.0 in its 95% CI. I believe that the anova is a conditional (sequential)
test; is intervals marginal or approximate? Which should I
2011 Jun 25
2
cluster() or frailty() in coxph
Dear List,
Can anyone please explain the difference between cluster() and
frailty() in a coxph? I am a bit puzzled about it. Would appreciate
any useful reference or direction.
cheers,
Ehsan
> marginal.model <- coxph(Surv(time, status) ~ rx + cluster(litter), rats)
> frailty.model <- coxph(Surv(time, status) ~ rx + frailty(litter), rats)
> marginal.model
Call:
coxph(formula =
2005 Mar 09
2
Structural equation models with R
Hello useRs,
I`m running structural equation models with R, but for one of my models the
below error message apears. I`m trying to change startvalues but without
success. The manual for sem package did not help me. Does anyone knows how to
change startvalues for iteration in sem package? Or it can be another problem
with the model?
Error in startvalues(S, ram, debug = debug, tol = start.tol)
2009 Mar 02
1
how to pass a command variable in DOS to R program in R CMD BATCH
Hi all,
I need to run a program (asreml) thousands of times and each time I have
to provide a slightly different dataset. Because I have to run asreml
under Windows (DOS or scripts) environment, I have trouble to pass a
command variable (or pointer variable or %counter in the following
example) to R program so at each counter R can generate a different data
set for asreml to run. Any
2003 Apr 29
1
plot with nlme
Using R v. 1.7.0 on Windows 2000
I would like to plot the fitted values of a model as a function of a
continuous covariate, augmented with data (e.g., augPred) grouping by
combinations of fixed effects. I have not been able to use augPred
effectively, and am wondering if it does not handle unbalanced data (3 out
of 192 missing).
I include below the model and an xyplot that almost does the
2013 Jan 22
4
Simple use of dcast (reshape2 package)
Suppose I have a small dataframe
> aa
Target Eaten ID
50 TPP 0 1
51 TPP 1 2
52 TPP 3 3
53 TPP 1 4
54 TPP 2 5
50.1 GPA 9 1
51.1 GPA 11 2
52.1 GPA 8 3
53.1 GPA 8 4
54.1 GPA 10 5
And I want to reshape it into
ID TPP GPA
1 1 0 9
2 2 1 11
3 3 3 8
4 4 1 8
5 5 2 10
I realise that
2018 Feb 14
2
Using gutenbergr with a firewall
I can use the gutenberg_download() function in the gutenbergr package
on a computer that doeson't use a firewall, but on an almost identical
installation that is behind a firewall, nothing happens, not even a
time-out.
Has anyone succeeded in using gutenberg_download() successfully with a
firewall? I tried raising an issue at
https://github.com/ropenscilabs/gutenbergr/issues/17 with no
2018 Feb 02
2
Updating Rcpp package when it is claimed by dplyr
Or, to avoid accusing you of lying. what you think is "vanilla" probably isn't. What exactly did you do? On Unix-likes, I would do something like this
echo 'options(repos=list(CRAN="cran.r-project.org"));install.packages("Rcpp")' | R --vanilla
(or maybe https://cloud.r-project.org is better...)
-pd
> On 2 Feb 2018, at 08:15 , Jeff Newmiller
2006 Oct 30
1
Which executable is associated with R CMD INSTALL?
I'm still having trouble installing the lme4 package on RHEL 3. I've
asked this list and it seems my problem is not universal. Brian
Ripley indicated that the problem was with recognising the Matrix
package, even though I've taken care to get the most recent versions
of Matrix and lme4.
It seems to me that the problem arises because the computer has a site
installation of R-2.3.1
2006 Oct 30
1
Which executable is associated with R CMD INSTALL?
I'm still having trouble installing the lme4 package on RHEL 3. I've
asked this list and it seems my problem is not universal. Brian
Ripley indicated that the problem was with recognising the Matrix
package, even though I've taken care to get the most recent versions
of Matrix and lme4.
It seems to me that the problem arises because the computer has a site
installation of R-2.3.1
2018 Feb 02
2
Updating Rcpp package when it is claimed by dplyr
When i tried to install the hunspell package, I got this error message:
Error: package ?Rcpp? 0.12.3 was found, but >= 0.12.12 is required by ?hunspell?
So I set about installing a new version of Rcpp but I get this message:
Error in unloadNamespace(pkg_name) :
namespace ?Rcpp? is imported by ?dplyr? so cannot be unloaded
How does one get around that? I tried installing Rcpp in a