Displaying 20 results from an estimated 8000 matches similar to: "pause/get input"
2001 Sep 14
3
stuff I used to do in Matlab
Hi,
I'm new to R, and trying to map stuff I knew how to do in Matlab
to R. For instances, in matlab, sum(x) gave the column sums of
matrix(/vector) x. In R it just gives the sum of all the elements,
regardless of their form (vector or matrix). Is there a simple way to
return a vector of column sums for a matrix? Also, in Matlab binary
operators exist for concatenating a matrix onto the end or
2001 Oct 30
2
extracting object names as strings
Hi,
I'm looking for a function which returns the name of the argument
object as a string:
>vect <- 1:3
>function(vect)
"vect"
I've looked at 'name', 'names', 'objects', none seem to do exactly what I
want. ls/objects comes close, but I can't figure out how to force it to
give me only one object name.
daver
2001 Oct 09
3
find indices of nonzero elements
Hi,
Is there a function func(x) where x is an array such that it
returns a list of the indices of all non-zero elements of the array?
for example:
a:
1 0 0
0 0 1
0 1 0
func(a) returns two vectors r and c:
r c
1 1
2 3
3 2
daver
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|David Richmond It works on a |
+ Dept. of Sociology complex scientific
2002 Mar 20
7
how does while work
i am having some problems with a program that i am writing and i think that
knowing how the while command works will help me to figure out where i am
going wrong
*when do you get kicked out of a while loop?*
(i.e., in the following example what would the final value of 'a' be?) i
thought it would be 99 but running it in R i get 101 (and 101 for x too!)
while (x <100) {
for (i in
2001 Oct 16
4
Assignment of structures on a given environment
Hi,
In order to avoid deep copies by passing large arguments to functions or
returning values, I'm trying to do the assignment of variables in a
given environment. The problem is when I try to assign a structure: a
list for example.
If I have:
ind <- c("a","b")
my idea is doing something like
l <- alist()
l[ind] <- as.list(c(20,40))
in a given
2001 Sep 28
3
evaluating the contents of a string
Hi,
suppose I do:
b <- matrix(1:9,3,3)
bname <- "b"
now
dim(b)
returns
[1] 3 3
and
dim(bname)
returns
NULL
is there a function to pass bname to such that dim returns the dimensions
of b?
like
dim(somefunc(bname))
returns
[1] 3 3
does 'somefunc' exist?
daver
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|David Richmond It
2001 Sep 29
1
how much memory does one need...
to allocate 7.8 MB to a vector? (on R running on MacOS 8.6 with a 100MB
partition)
I get this error from a function which is trying to create a 1000x1000
matrix:
Error: cannot allocate vector of size 7812 Kb
the error occurs here:
dist <- as.single((t(pos)-pos)/n)
where pos is a matrix of integers, and n is the size of the first
dimension. It appears to first create a double with
2002 Feb 28
1
postscript output sideways
Hi,
My plots are all coming out sideways! If I do the following:
> postscript("plot1.ps",horizontal=TRUE,paper="letter")
> plot(ns,meanpl/maxvec)
> dev.off(2)
The output file has "ns" on the left and the "meanpl/maxvec" on the top!
It doesn't matter if I change the horizontal flag to FALSE.
I have noticed, however that If I create my own
2001 Oct 14
1
recursive functions and global variables
Hi,
I am trying to write a recursive routine which passes some
variables through the function calls but also refers to some global
variables. I need the global variables because they are very big (n by n
matrices where n is <= 1000) and I don't have the huge amount of memory
needed to spawn dozens of copies of these matrices. The problem seems to
be that while variables in the root
2002 Apr 12
2
Help
I have an adjacency matrix and I want to obtain a matrix of the minimum
paths between the nodes. Thank you
Alessandro Ambrosini
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)
2001 Dec 14
0
polylog
Hi,
Does R do the "PolyLog" function, also know as Jonquiere's
function: Li-n(z) = sum over k= 1 to inf. of (z^k)/(k^n) ?
dave
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|David Richmond It works on a |
+ Dept. of Sociology complex scientific +
|Saint Mary's College principle, known as |
+ Notre Dame, IN
2001 Nov 15
6
two plots in one frame
I would like to plot two different scatterplots in the same frame (say with
different colors) but everytime plot is called a new frame is created. Is
there a way around this?
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or
2002 Jan 27
1
cran@ci.tuwien.ac.at is not responding?
Hi,
I have submitted a package to CRAN in
ftp://ftp.tuwien.ac.at/incoming/pastecs_1.0.tar.gz. The R extension manual
advises to send a mail to cran at ci.tuwien.ac.at about it, but it fails. I
have also tried WWWadmin at ci.tuwien.ac.at. Are these email adresses still
valid?
Best,
Philippe Grosjean
...........]<(({?<...............<?}))><...............................
) ) ) )
2001 Aug 27
4
plotting dendrograms from cluster analyses
Hi all,
I have a bit of a newbie question here that I hope y'all can help with. I've
run a cluster analysis using hclust on about 500 objects (using R1.3 under
Win 2000). The problem is that the tips of the dendrogram are so close
together on the plot that the labels overlap and are unreadable. I've used
"cex" to reduce the label sizes but this isn't sufficient with so
2001 May 16
5
the R package - relation to R project?
I stumbled across this link and was wondering if this has any relation to
the R project.
http://www.fas.umontreal.ca/BIOL/Casgrain/en/labo/R/index.html
-jennifer
-----------------------------------
J. Steinbachs, Ph.D.
Computational Biologist
http://compbiology.org
-----------------------------------
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing
2005 May 07
1
Incorrect libxml2.2.dylib version on Tiger install
Hi all,
I have just installed OSX Server 10.4 and R comes up with the
incompatible libxml library message reported by Dan Kelley a few
messages ago. Xcode 2 does not ship with Tiger Server. I installed
the X-Windows code. I can report that the version of libxml2.2 that is
installed in this case is the version 8.0.0 dylib.
[6]sboker at munimula:/usr/lib % ls -l libxml2.2*
-rwxr-xr-x 1
2001 Oct 09
2
list of functions flagged with debug() or trace()
Hello all,
Since I got no answer to my first mail, I suspect I did not formulate my
question adequately, so I try again.
In R, one can debug or trace a function 'foo' with debug(foo) or trace(foo),
respectively. This leads to a special treatment of the function 'foo' until
one enter undebug(foo) or untrace(foo). I would like to know if there is a
convenient way to know at any
2002 Mar 15
1
creating time series from existing data
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Is it possible to create a time series from existing data frame? One
column of that frame contains dates (like "01/01/01") and the second one
the values. The period is non-regular (it is not strictly daily nor
working-days-daily).
Thank you.
lukas
- --
Lukas Kubin
lukas.kubin at permonik.com
phone: 00420603836180
-----BEGIN PGP
2001 Aug 08
3
"Transparent" background in graphics exported as metafiles
Hi,
Under Windows, I am exporting graphs from R (in metafile -emf- format), and
want to combine them using a graphic package. It happens that the background
of the graph is represented by a filled rectangle (with the color given by
bg=...). This is to be expected. However, I find no options to disable this
and produce a graph with transparent background. Does such an option exist?
If not, then
2001 Sep 05
2
Replacing NAs with interpolated values
Hi there,
I've got this vector:
-84 -87 -90 -90 -89 -86 NA NA NA NA NA NA NA NA NA NA NA NA -96
-99 -100 -99 -96 -92 -89 -87 -87 -88 -90 -92 -94 -95 -96
-97 -97 -97 -96 -95
Is there a function in R which replaces the NAs with "interpolated"
values between -86 and -96?
Thanks, Sven