On Sun, Apr 1, 2012 at 4:20 PM, Duncan Mackay mac...@northnet.com.au wrote:
Hi
There are a number of packages that produce latex from R, Sweave, brew,
knitr - ones that come to mind. It happens that i use Sweave.
The package you finally use may depend on your preferences
The graphic output
My $.01 contribution without having read the complete thread:
Some other process/service is locking your file/directory. There are
a few Windows tools out there helping your to narrow down exactly
which, e.g.
http://www.guidingtech.com/10175/tools-to-delete-locked-files-in-windows/
/Henrik
See ?closeAllConnections
Suggestion to the maintainer of Sweave: atomify the figure
generation, e.g. use { pdf(); on.exit(dev.off()); {...}; } or similar,
instead of { pdf(); {...}; dev.off(); } possibly by leaving a copy of
the fault figure file for troubleshooting.
/Henrik
On Wed, Apr 4, 2012
str() is your number one friend in R. Do str(A) and str(A2) after
allocating the matrices and you'll be surprised. My $.02 /Henrik
On Fri, Apr 6, 2012 at 7:35 AM, 卢永芳 sswwss...@126.com wrote:
Hello,experts
I am working on a simulation of effect of artificial selection on certain
population
On Sat, Apr 7, 2012 at 1:30 PM, Mark Heckmann mark.heckm...@gmx.de wrote:
Hello,
using the - assignment operator I do not understand why the following does
not work.
l - list()
l
list()
l$arg1 - test
error in l$arg1 - test : Objekt 'l' not found
?- says: The operators - and - cause a
, e.g. rm(list=ls(all.names=TRUE)).
FYI, this updated topic may be better suited for the R-devel list.
/Henrik
TIA
--Mark
Am 07.04.2012 um 22:51 schrieb Henrik Bengtsson:
On Sat, Apr 7, 2012 at 1:30 PM, Mark Heckmann mark.heckm...@gmx.de wrote:
Hello,
using the - assignment operator I
See also R help thread 'Wait for keystroke or timeout':
http://www.mail-archive.com/r-help@r-project.org/msg97742.html
/H
On Mon, Dec 6, 2010 at 9:11 PM, Michael Bedward
michael.bedw...@gmail.com wrote:
Below is a toy function with one way of doing it. There are bound to
be better ways :)
First, subset 'test' once, e.g.
testT - test[1:3];
and then use sapply() on that, e.g.
val - sapply(testT, FUN=function (x) { x$a })
Then you can avoid one level of function calls, by
val - sapply(testT, FUN=[[, a)
Second, there is some overhead in [[, $ etc. You can use
.subset2() to avoid
Hi
On Wed, Dec 8, 2010 at 11:18 PM, Ganqiang Liu g@imb.uq.edu.au wrote:
Is there a bug in tiff compression output in Mac version?
My program is correct when I run on windows version; However, in Mac, the
compression fail~
Friendly and constructive sarcasm follows:
Talking cars, your
FYI,
I've added evalWithTimeout() to R.utils v1.6.0 (now on CRAN). It
utilizes the built-in setTimeLimit() feature of R.
You can either have it throw an error, which you then have to catch,
or you can have it just give a warning that your evaluation timed out
and then silently continue. From
Hi,
I am using Octave; what does that save options do, more specifically,
is compression taking place when saving that file?
If compression is done, then the Rcompression package is utilized by
R.matlab (otherwise not). BTW, you don't have to load Rcompression
explicitly; R.matlab will do it
On Tue, Dec 21, 2010 at 10:15 AM, Henrik Bengtsson h...@biostat.ucsf.edu
wrote:
Hi,
I am using Octave; what does that save options do, more specifically,
is compression taking place when saving that file?
That should be: I am [not] using Octave... /H
If compression is done
It is easier than that. Use
http://www.bioconductor.org/packages/release/bioc
or
http://www.bioconductor.org/packages/devel/bioc
/Henrik
On Mon, Jan 24, 2011 at 10:56 AM, Martin Morgan mtmor...@fhcrc.org wrote:
On 01/24/2011 10:45 AM, Kevin Wright wrote:
I currently set the Bioconductor
2011/11/1 Ernest Adrogué nfdi...@gmail.com:
Hi,
On ocasion, you need to subscript an array that has an arbitrary
(ie. not known in advance) number of dimensions. How do you deal with
these situations?
It appears that it is not possible use a list as an index, for
instance this fails:
x -
See downloadFile() of the R.utils package (on CRAN);
it allows you to download to a file to a given path (without have to
replicate the filename), and it also have an option (the default) to
drop zero-size files that are (sometimes) created when download.file()
tries to download a non-existing
FYI,
you can use tools such as Path Manager 1.1.1 (GPL) on Windows:
http://www.softpedia.com/get/System/System-Miscellaneous/Path-Manager.shtml
to list, modify (add, remove, reorder, remove duplicates, normalize)
your PATH environment variable. For each directory it identifies in
PATH it will
See if
Rcmd check --help
works.
I've always been use that form (I'm on Win7 64-bit).
/Henrik
On Mon, Nov 14, 2011 at 9:06 AM, Martyn Byng martyn.b...@nag.co.uk wrote:
Hi Josh,
Thanks for that, which directory needs to be in the path?
There is a file called R.exe in
C:\Program
file.path() is much better for this than paste(), e.g.
dir - C:/Users/Desktop
pathname - file.path(dir, bs_dev_segment_file.csv)
temp_data - read.csv(pathname)
/Henrik
On Tue, Nov 15, 2011 at 10:08 AM, R. Michael Weylandt
michael.weyla...@gmail.com michael.weyla...@gmail.com wrote:
Try pasting
...because you're catching the timeout error with try() so it has not
effect, and hence the while(TRUE) {} loop keeps running.
Without knowing anything about graphics event handlers per se, here's
an alternative to catch the timeout event:
library(R.utils);
plot(0, 0);
eventEnv -
Hi.
On Wed, Dec 21, 2011 at 4:20 AM, beetonn nicholas.bee...@utas.edu.au wrote:
Thanks, Henrik! That's given me some food for thought, and evalWithTimeout
certainly seems to be a nicer way of doing this than setTimeLimit.
I should probably explain a little more clearly: I want to stop
On Thu, Dec 22, 2011 at 4:34 AM, David A Vavra dava...@verizon.net wrote:
I want to take slices of a multi-dimensional table (or array) without
knowing the number of dimensions in advance.
As a test I tried using (in this example a 3d table):
do.call(`[`, list(tbl, x,NULL,NULL)]
You could generate an R script using an RSP template 'main.R.rsp' containing:
% DEBUG - TRUE %
% if (!DEBUG) { %
make_addition = function(a, b) {
% } %
% if (DEBUG) { %
a = 1
b = 2
% } %
c=a+b
plot(c)
% if (!DEBUG) { %
return(c)
}
% } %
which you can compile into 'main.R'
[R] False Virus detection with colorspace package? [Tue Nov 8 00:44:37 CET 2011]
https://stat.ethz.ch/pipermail/r-help/2011-November/294875.html
/H
On Tue, Jan 24, 2012 at 11:46 AM, Stephen P Molnar
s.mol...@sbcglobal.net wrote:
I keep finding the Win32\Huer virus in colorspace_1.1-1.zip for R
The quick solution:
parseAndEval - function(x, ...) eval(parse(text=x))
apply(BM, MARGIN=c(1,2), FUN=parseAndEval)
My $.02
/Henrik
On Mon, Jan 30, 2012 at 10:26 AM, Paul Johnson pauljoh...@gmail.com wrote:
A user question today has me stumped. Can you advise me, please?
User wants a matrix
I may be wrong, but I don't think unz() handles bz2 files - only zip files.
See bunzip2() of the R.utils package (which utilizes bzfile connections).
/Henrik
On Tue, Jan 31, 2012 at 2:34 PM, ql16717 ql16...@gmail.com wrote:
Hi,
I have downloaded a bunch of bz2 files. I wonder if R will be
For these type of setups, I typically turn to default values, e.g.
hatvalues.mlm - function(model, m=1, infl=NULL, ...)
{
if (is.null(infl)) {
infl - mlm.influence(model, m=m, do.coef=FALSE);
}
hat - infl$H
m - infl$m
names(hat) - if(m==1) infl$subsets else
Try adding --vanilla when calling R, e.g.
R --vanilla --no-save --args 5 test1.R
because I think you're picking up and previously stored session.
You'll most likely will find that res - conditional1(x) will give
an error saying 'conditional1' is not defined; you need to define the
function
On Sun, May 15, 2011 at 9:31 AM, Spencer Graves
spencer.gra...@structuremonitoring.com wrote:
Also: A previous post in this tread suggested Rprof [sec. 3.2 in Writing
R Extensions, available via help.start()]. This should identify the
functions that consume the most time. The standard
-styleguide.googlecode.com/svn/trunk/google-r-style.html]
[4] R style guide by Hadley Wickham (based on [3])
http://had.co.nz/stat405/resources/r-style-guide.html
[5] R Coding Conventions (RCC) - a draft by Henrik Bengtsson
http://aroma-project.org/developers/RCC
[6] The Aroma R Coding
You may have to tune the curve fitting parameters. Have a look at
arguments 'smoother' and '...' in help(principal.curve), i.e. by
default principal.curve() uses smoother function smooth.spline() in
each iteration and principal.curve() passes down any additional
arguments to it that you give (via
FYI,
Rtools212.exe:
File size: 44,224,666 bytes
MD5:15ce69dcfc989c43825bedeaa8389aa6
Rtools213.exe:
File size: 38,122,354 bytes
MD5: 09052655da7c6e8a81f2d398ed6004b5
/Henrik
On Thu, Jun 9, 2011 at 6:12 AM, Martyn Byng martyn.b...@nag.co.uk wrote:
Hi,
Apologies if this is the wrong list to
See ?get and ?do.call. That should be enough.
?Reduce may be an alternative for do.call(), but could also be less
memory efficient.
My $.02
/Henrik
On Thu, Jun 9, 2011 at 7:57 PM, Ben Zaitchik zaitc...@jhu.edu wrote:
Hello,
I have a large number of raster objects in memory, with names
...and ?mget for retrieving multiple objects as a list. /Henrik
On Thu, Jun 9, 2011 at 10:32 PM, Henrik Bengtsson h...@biostat.ucsf.edu wrote:
See ?get and ?do.call. That should be enough.
?Reduce may be an alternative for do.call(), but could also be less
memory efficient.
My $.02
Hi W. Kaisers,
sorry for the delay - I just spotted you question:
On Thu, Jun 16, 2011 at 5:52 AM, kais...@med.uni-duesseldorf.de wrote:
Dear R.oo package users,
while testing some functionality of the R.oo, I found that during the first
construction of a object from a class, the
See file.path().
/Henrik
On Tue, Jun 28, 2011 at 6:59 PM, Jonathan Greenberg
greenb...@ucdavis.edu wrote:
Hopefully this is a pretty easy fix -- I need to have R query the path
separator for some code I'm trying to write (it involves using a
system() call) -- the call requires a path and a
Christof,
I've added support for this to the R.filesets package. In your case,
then all you need to do is:
library(R.filesets)
dlf - readDataFrame(filename, skip=^year)
No need to specify any other arguments - they're all automagically
inferred - and the default is stringsAsFactors=FALSE.
See abort() in the R.oo package, with some discussion here
https://stat.ethz.ch/pipermail/r-devel/2012-September/064838.html
/Henrik
On Wed, Feb 6, 2013 at 7:05 PM, Jeff Newmiller jdnew...@dcn.davis.ca.us wrote:
stop() does not have momentum... it is designed to play nice.
Perhaps you want
You probably meant
testInstalledPackage(base)
without the 's', cf. help(testInstalledPackage, package=tools).
/Henri
On Tue, May 29, 2012 at 4:18 PM, jalantho...@verizon.net
jalantho...@verizon.net wrote:
I installed R version 2.15.0 under C:/ on a PC running Windows 7. When I
load
FYI,
isZero - function(x, neps=1, eps=.Machine$double.eps, ...) {
+ (abs(x) neps * eps)
+ }
x - seq(from=0, to=4, by=0.1)
isZero(x[4]-0.3)
[1] TRUE
isZero(x[4]-0.3, neps=1)
[1] TRUE
isZero(x[4]-0.3, neps=0.1)
[1] FALSE
You could also have called isZero() isValueSmallEnoughForWhatINeed().
FYI, from help(layout, package=graphics):
[...]
Warnings
These functions are totally incompatible with the other mechanisms for
arranging plots on a device: par(mfrow), par(mfcol) and split.screen.
/Henrik
On Wed, Jun 20, 2012 at 3:17 PM, R. Michael Weylandt
michael.weyla...@gmail.com wrote:
Install the two versions in two different *libraries* and update
.libPaths() to prioritize one over the other. /Henrik
On Tue, Oct 2, 2012 at 1:18 PM, Søren Højsgaard sor...@math.aau.dk wrote:
Dear list,
I am making some comparisons of two versions of the lme4 package: The CRAN
version and
You didn't say what errors you've got but you probably wants to
specify argument mode=wb in your download.file() call, cf.
https://stat.ethz.ch/pipermail/r-devel/2012-August/064739.html
/Henrik
On Mon, Oct 15, 2012 at 1:57 AM, veepsirtt veepsi...@gmail.com wrote:
Hi
Download the xls file
'readWorksheet': Error: object 'wb' not found
On Mon, Oct 15, 2012 at 11:58 PM, Henrik Bengtsson-3 [via R]
ml-node+s789695n4646268...@n4.nabble.com wrote:
You didn't say what errors you've got but you probably wants to
specify argument mode=wb in your download.file() call, cf.
https://stat.ethz.ch
Hi,
I've successfully used it on a Linux setup, but when I try to load
rJava on Windows 7 64-bit (session info below) I get:
% R --vanilla
library(rJava)
Error : .onLoad failed in loadNamespace() for 'rJava', details:
call: dirname(this$RuntimeLib)
error: a character vector argument
Hi,
see the R.devices package
[http://cran.r-project.org/web/packages/R.devices/]. FYI, there is a
vignette [R.devices-overview.pdf], but for some reason it's hard find.
However it is there: help.start() - R.devices - 'User guides,
package vignettes and other documentation.' -
Sorry, forgot to add: Hi, [a somewhat different approach but] see the
R.devices package /Henrik
On Sun, May 26, 2013 at 10:14 AM, Henrik Bengtsson h...@biostat.ucsf.edu
wrote:
Hi,
see the R.devices package
[http://cran.r-project.org/web/packages/R.devices/]. FYI, there is a
vignette
On Tue, Jun 11, 2013 at 2:14 PM, David Winsemius dwinsem...@comcast.net wrote:
On Jun 11, 2013, at 9:01 AM, Bikash Agrawal wrote:
Is there any packages available in R, that can convert Bytes array to Float.
Using rJava we can do it. But it is kind of slow. Is there any R
specific packages.
See evalWithTimeout() of R.utils, e.g.
tryCatch({
evalWithTimeout({
slowFunction();
}, timeout=7*24*3600);
}, TimeoutException=function(ex) {
cat(Timeout. Skipping.\n);
})
help(evalWithTimeout) have more information and cross links.
/Henrik
On Thu, Jul 18, 2013 at 11:37 AM, ONKELINX,
Try with adding mode=wb to download.file(), or just use
downloadFile() of R.utils.
/Henrik
On Sun, Jul 28, 2013 at 8:32 PM, Yong Wang wangyo...@gmail.com wrote:
Dear list,
I am working with R to download numerous html source code from which the
data extracted will be further processed.
The
See Suraj Gupta's online article 'How R Searches and Finds Stuff' from
March 29, 2012:
http://obeautifulcode.com/R/How-R-Searches-And-Finds-Stuff/
It's a very useful write up on this topic.
/Henrik
On Sat, Mar 8, 2014 at 3:42 PM, Benjamin Tyner bty...@gmail.com wrote:
Duncan,
Thank
I don't think you got a response to this one;
x - array(dim=(c(j, n)))
for (i in 1:n) {
x[,i] - rnorm(j)
}
Note that array() allocates a logical array by default, which means
that in your first iteration (i==1) it has to be coerced to a double
array before assigning the value
[Sounds like a question for R-devel]
On Wed, Apr 9, 2014 at 5:02 AM, Tal Galili tal.gal...@gmail.com wrote:
Hello all,
I wish to add to the
installrhttp://cran.r-project.org/web/packages/installr/package the
ability to check for new versions of R once every X units of
time (maybe once
Two quick comments:
1. You do not need to reset the timeout limits yourself; it's already
taken care of, cf. help(evalWithTimeout).
2. Have you tried example(evalWithTimeout)? It should illustrate how
it works/is used. It's also a good example to verify that it also
works on your machine (I'd
See blog post 'Speed trick: Assigning large object NULL is much faster
than using rm()!':
http://www.jottr.org/2013/05/speed-trick-assigning-large-object-null.html
/Henrik
On Tue, Jun 3, 2014 at 5:35 PM, Ista Zahn istaz...@gmail.com wrote:
Hi Frank,
I don't think it is possible to state a
cl - quote(round(10.5))
deparse(cl)
[1] round(10.5)
/Henrik
On Tue, Jun 3, 2014 at 8:07 PM, Spencer Graves
spencer.gra...@structuremonitoring.com wrote:
How can I get a call object as a character string?
Example:
cl - quote(round(10.5))
str(cl)
language round(10.5)
Make sure that the last line has a newline at the end, otherwise that
expression will be silently ignored, cf. R-devel thread '[Rd] Last
line in .Rprofile must have newline (PR#4056)' on 2003-09-03
[https://stat.ethz.ch/pipermail/r-devel/2003-September/027455.html].
I'm pretty sure many many
See findSourceTraceback() of R.utils. /Henrik
On Mon, Aug 26, 2013 at 10:58 PM, peter dalgaard pda...@gmail.com wrote:
On Aug 27, 2013, at 07:12 , nevil amos wrote:
Is there a fuction that will allow me to retrun the filename for a script
from within that script.
Not a standard one, but
On Sun, Aug 25, 2013 at 10:55 AM, Christofer Bogaso
bogaso.christo...@gmail.com wrote:
Hello again,
I need to install Rmpi package from this
http://www.stats.uwo.ca/faculty/yu/Rmpi/download/windows/MPICH2
I was wondering if there is any direct way to install this in R. The
trivial method
I strongly suggest to use the BatchJobs package
[http://cran.r-project.org/web/packages/BatchJobs] for this. It is
easy to install and cross platform and does not rely on external
software such as perl. It allows you develop your script running
sequentially/interactively on your local
Unless you're trying to provide your startup settings to multiple
users (typically only sysadms do this), stick with .Rprofile (in your
home directory). There is no need to have one per working directory,
unless they differ, cf. ?Startup [...a file called ‘.Rprofile’ is
searched for in the
system2(sed, args=c(-i, s/oldword\\s/newword/g, d:/junk/x/test.tex))
/Henrik
On Fri, Oct 11, 2013 at 8:58 AM, David Winsemius dwinsem...@comcast.net wrote:
On Oct 10, 2013, at 8:16 AM, Zev Ross wrote:
Hi All,
I'm trying to edit a file in place using system2 and sed from within R. I
can
On Mon, Oct 21, 2013 at 4:12 PM, Alexandre Khelifa
akhel...@logitech.com wrote:
Hi,
My name is Alexandre Khelifa and I have been using R at my work for about 2
years. I have been working on a project when we do Monte Carlo Simulation
and it involves a lot of calculations.
I am currently
On Tue, Oct 22, 2013 at 8:03 PM, Marc Girondot marc_...@yahoo.fr wrote:
Dear list members:
I try to check my updated package to include a new version in CRAN
(phenology) but a new error is indicated and I don't find the logic.
First my system:
* using R version 3.0.2 Patched (2013-09-27
Have you tried to download from another CRAN mirror, e.g.
http://cran.r-project.org/web/packages/XML/
More mirrors at http://cran.r-project.org/mirrors.html
As already others said, it's very unlikely that this is not an issue
on your end.
/Henrik
On Thu, Oct 24, 2013 at 4:54 AM, Steven
On Fri, Nov 30, 2012 at 9:43 AM, Luca Meyer lucam1...@gmail.com wrote:
Hello R-experts,
I would like to know if there is a solution to read files with extension
.gsheet directly into R - see http://www.fileinfo.com/extension/gsheet for
more info on this file format.
AFAIK, those files
If all you need to do is to set environment variables, you can do that
from within R, e.g.
shell(echo %FOO%)
%FOO%
Sys.setenv(FOO=42);
shell(echo %FOO%)
42
My $.02
On Sun, Dec 23, 2012 at 11:14 AM, Ludwig Hilger l.hil...@ku.de wrote:
Dear list,
I have found a thread dealing with similar
On Wed, Feb 2, 2011 at 7:25 PM, Peter Langfelder
peter.langfel...@gmail.com wrote:
On Wed, Feb 2, 2011 at 7:22 PM, Nick Matzke mat...@berkeley.edu wrote:
Oh wait, this basically does it:
if (a %in% attributes(z)$names)
+ print(TRUE)
[1] TRUE
(but there may be a better way)
If z is a
FYI,
you can use the following to troubleshoot what is going on:
library(R.utils);
filename - MyFile.csv;
path - ... # The directory where to store
pathname - Arguments$getWritablePathname(filename, path=path);
or if you already have the full pathname:
pathname -
On Tue, Feb 22, 2011 at 7:43 AM, John Edwards jhnedwards...@gmail.com wrote:
Hi,
I have the following input file.
$ cat main.txt
CEL_A CELL_B
1 4
2 5
2 6
Then I run read.table in R.
f=read.table('main.txt', header=T, check.names=F, sep='\t')
head(f)
\ufeffCEL_A CELL_B
1 1 4
On Wed, Feb 23, 2011 at 1:02 PM, Martin Maechler
maech...@stat.math.ethz.ch wrote:
RK == Rumen Kostadinov rkost...@gmail.com
on Sun, 13 Feb 2011 12:46:52 -0500 writes:
RK Thanks Sarah,
RK Yes, the function behaves Exactly as documented:
RK check this out:
a = c(1,2,3,4,5)
Hi,
the R.filesets package was designed for this. It is heavily used by
the aroma framework (http://www.aroma-project.org/), so it got a fair
bit of mileage now (in a good a way). Here is how you could setup
your data set and work with the data.
# - - - - - - - - - - - -
# Setup file data set
It would be nice to have a standard directory where R can write things
this way. A semi-standard directory is given by
Sys.getenv(R_LIBS_USER), which defaults to ~/R/.../. Maybe ~/R/
could serve as that convention? That way we (various developers etc)
would also not clutter up users home
Today it's 16 years ago and 367,496 messages later since MartinMächler
started the R-help (321,119 msgs), R-devel (45,830 msgs) and
R-announce (547 msgs) mailing lists [1] - a great benefit to all of
us. Special thanks to Martin and also thanks to everyone else
contributing to these forums.
[1]
See ?readBin - works also with raw objects.
Henrik
On Apr 3, 2013 1:18 AM, Mike Chen chenminyi1...@gmail.com wrote:
I know that there is a function to convert binary data to string named
rawToChar.but I wander is there any similar function for Integer and
float.I need to read some binary file
FYI,
(0.29*100) 29
[1] TRUE
See R FAQ 7.31 for why.
/Henrik
On Tue, Apr 9, 2013 at 9:11 AM, Jorge Fernando Saraiva de Menezes
jorgefernandosara...@gmail.com wrote:
Dear list,
I have found an unusual behavior and would like to check if it is a
possible bug, and if updating R would fix it.
See for instance capitalize() in the R.utils package.
Henrik
On Apr 14, 2013 11:51 PM, Liviu Andronic landronim...@gmail.com wrote:
Dear all,
Given the following vector:
(z - c('R project', 'hello world', 'something Else'))
[1] R project hello worldsomething Else
I know how to
I'm pretty sure the intended design is to always use the current
working directory as the output directory, cf. 'Value' section in
help(texi2dvi, package=tools):
Used for the side effect of creating a dvi or PDF file in the current
working directory (and maybe other files, especially if clean =
On Sat, Apr 20, 2013 at 3:10 PM, Knut Krueger r...@knut-krueger.de wrote:
Am 20.04.2013 15:50, schrieb Gabor Grothendieck:
Note that there is a separate directory for the 64-bit R executables.
Does it make any difference to check and pack the source files iwth 32 or 64
bit?
Also,
FYI,
whenever getting an error, run traceback() *immediately after* (i.e.
before any other commands) and include that in your error report.
Also include the output of sessionInfo(). It helps tremendously and
spares lots of second guessing.
/Henrik
On Wed, Apr 11, 2012 at 8:28 AM, krtek
May be of use too:
The R Foundation for Statistical Computing, R: Regulatory Compliance
and Validation Issues - A Guidance Document for the Use of R in
Regulated Clinical Trial Environments, August 17, 2008
[http://www.r-project.org/certification.html]
/Henrik
On Thu, Apr 12, 2012 at 1:06 PM,
On Mon, Apr 16, 2012 at 9:13 PM, Worik R wor...@gmail.com wrote:
After a lot of processing I get a matrix into M. I expected each row and
column to be a vector. But it is a list.
Lists are also vectors, e.g.
x - list()
is.vector(x)
[1] TRUE
y - vector(list, length=3)
str(y)
List of 3
$
paleotree imports phangorn which depends on Matrix, so your example
does indeed depend on Matrix.
A possible reason is that your installed Matrix was built for a
different version of R, i.e. check packageDescription(Matrix).
/Henrik
On Tue, Apr 17, 2012 at 4:23 PM, David Bapst
You could do:
library(R.utils);
value - loadToEnv(MyFile.RData)[[nameOfObject]];
It still load all of the data, but it is not kept; only the object you grab.
/Henrik
On Tue, Apr 24, 2012 at 11:30 AM, Shi, Tao shida...@yahoo.com wrote:
Hi list,
Is there a way to load one specific object
If it helps... R is not Matlab. There is no '.*' operator in R.
/H
On Thu, Apr 26, 2012 at 2:37 PM, Sarah Goslee sarah.gos...@gmail.com wrote:
On Thu, Apr 26, 2012 at 5:34 PM, Guaramy _ guar...@hotmail.com wrote:
Thanks for your answer, but how can i correct that, the mathematical
expression
On Thu, Apr 26, 2012 at 3:21 PM, Kamil Slowikowski
kslowikow...@gmail.com wrote:
My goal is simple: calcuate GC content of each sequence in a list of
nucleotide
sequences. I have figured out how to vectorize, but all my attempts at
memoization failed.
Can you show me how to properly memoize
An R solution is:
allocateFile - function(pathname, nbrOfBytes) {
con - file(pathname, open=wb);
on.exit(close(con));
seek(con, where=nbrOfBytes-1L, origin=start, rw=write);
writeBin(as.raw(0), con=con);
invisible(pathname);
} # allocateFile()
allocateFile(foo.bin, nbrOfBytes=985403)
On Sat, May 5, 2012 at 2:10 PM, Hillary Sardiñas herongr...@gmail.com wrote:
I have been trying to download the latest version to my Macbook X version
10.6.8 from my institutions mirror http://cran.cnr.Berkeley.edu
Usually is only takes minutes, but regardless of the browser or where I
connect
You need to specify that you want a binary download - make sure to
read help(download.file), particular that of argument 'mode'.
Alternatively, use downloadFile() in the R.utils package which
download as binary by default.
/Henrik
On Sat, May 19, 2012 at 7:22 AM, sagarnikam123
See rowMedians() of the matrixStats package for replacing apply(x,
MARGIN=1, FUN=median). /Henrik
On Tue, May 22, 2012 at 12:34 PM, Preeti pre...@sci.utah.edu wrote:
Hi,
I have a 250,000 by 300 matrix. I am trying to calculate the median of
those columns (by row) with column names that are
(colnames(df)), function(x)
rowMedians(as.matrix(df[,colnames(df) == x]),na.rm=TRUE))
Thanks again!
On Tue, May 22, 2012 at 3:23 PM, Henrik Bengtsson h...@biostat.ucsf.edu
wrote:
See rowMedians() of the matrixStats package for replacing apply(x,
MARGIN=1, FUN=median). /Henrik
On Tue, May
On Wed, Dec 4, 2013 at 6:53 PM, Greg Snow 538...@gmail.com wrote:
As you have noticed, using assign is not simple, and your approach has
potential to cause even more problems even if you get it working.
Here is another approach:
loadCSVfiles - function(path) {
x - list.files(path,
FYI, in R.utils (= 1.28.4) you can use listDirectory() to control how
deep the recursion goes, which would give you protection against your
problem, e.g.
R.utils::listDirectory(dir, recursive=5L)
where recursive=0L is equivalent to recursive=FALSE. Using
recursive=TRUE corresponds to
See ?png and argument 'pointsize'. You can increase that as you
increase the dimensions of the output image.
/Henrik
On Sun, Dec 15, 2013 at 3:00 PM, david hamer j.david.ha...@gmail.com wrote:
Hello,
My x-y scatterplot produces a very ragged best-fit line when imported into
Word.
* plot
And possibly better, argument 'res', e.g.
png(R.graph.png, width=1200, height = 700, res=144)
plot(...)
dev.off()
Default corresponds to res=72.
/Henrik
On Sun, Dec 15, 2013 at 3:13 PM, Henrik Bengtsson h...@biostat.ucsf.edu wrote:
See ?png and argument 'pointsize'. You can increase
What about
seq_len2 - function(length.out, from=1L) {
seq(from=from, length.out=max(0L, length.out-from+1L))
}
lapply(0:4, FUN=seq_len2, from=2L)
[[1]]
integer(0)
[[2]]
integer(0)
[[3]]
[1] 2
[[4]]
[1] 2 3
[[5]]
[1] 2 3 4
/Henrik
On Sat, Dec 21, 2013 at 2:57 PM, Göran Broström
The answer most likely is in the message:
'\\homer.win.ad.jhu.edu\users$\rvaradh1\Documents'
CMD.EXE was started with the above path as the current directory.
UNC paths are not supported. Defaulting to Windows directory.
That path starting with a \\ is a *UNC path* (a Windows thing), which
I
On Thu, Jan 9, 2014 at 11:04 AM, Henrik Bengtsson h...@biostat.ucsf.edu wrote:
The answer most likely is in the message:
'\\homer.win.ad.jhu.edu\users$\rvaradh1\Documents'
CMD.EXE was started with the above path as the current directory.
UNC paths are not supported. Defaulting to Windows
Unless you have the same issues using plain R, this sounds like a question
specific to RStudio which needs to be addressed to
https://support.rstudio.com/
Henrik
On Jan 15, 2014 6:35 AM, Ronaldo Reis Júnior chryso...@gmail.com wrote:
Hi all,
I has astrange problem with Rstudio desktop and X11
As you install basically all CRAN packages and all OSes;
install.packages(forecast)
/Henrik
On Mon, Jan 27, 2014 at 8:18 PM, ce zadi...@excite.com wrote:
Sorry if the question is stupid, how you you install mac os binaries like in
:
.
-Original Message-
From: Henrik Bengtsson [h...@biostat.ucsf.edu]
Date: 01/28/2014 12:30 AM
To: ce zadi...@excite.com
CC: r-help@r-project.org
Subject: Re: [R] How do you install cran mac binaries
As you install basically all CRAN packages and all OSes;
install.packages
301 - 400 of 557 matches
Mail list logo