Displaying 20 results from an estimated 10000 matches similar to: "What is the fastest way to combine all columns of a matrix to one column?"
2010 Jun 15
2
Fastest way to merge matrix columns into a comma delimited string?
Folks:
Say I have a matrix:
test=matrix(c(1,2,3),nrow=10,ncol=3)
I would like to have an output character vector where each line is
row's values delimited by commas, e.g.:
"1,2,3"
"2,3,1"
"3,1,2"
...
"1,2,3"
What is the fastest way of doing this? I can paste() row-by-row but
this seems an inefficient approach to doing this. Thanks! I'm not
2001 Sep 04
2
fastest way to multiply each column of a matrix by a single vlaue
Let A be a m by n matrix and b a length n vector. What is the fastest
vectorized code for doing
for(j in 1:n) A[, j] <- A[, j]/b[j] ?
solution 1:
t(t(A)/b)
solution 2:
B <- matrix( rep(b, m), byrow=T, nrow=m )
A/B
anything else?
I have a program that uses this kind of operation million of times and
I appreciate your input.
Thanks.
Jason Liao
=====
Jason G. Liao
Department of
2013 Jan 29
4
Fastest way to compare a single value with all values in one column of a data frame
Hello!
I have a large data frame x:
x<-data.frame(item=letters[1:5],a=1:5,b=11:15) # in actuality, x has 1000
rows
x$item<-as.character(x$item)
I also have a small data frame y with just 1 row:
y<-data.frame(item="f",a=3,b=10)
y$item<-as.character(y$item)
I have to decide if y$a is larger than the smallest of all the values in
x$a. If it is, I want y to replace the whole
2011 Dec 11
3
Bioconductor. MA plot for qPCR array
Dear all,
Is there anyway too generate MA plot for 2 qPCR assays (an array of 2x 400).
--
View this message in context: http://r.789695.n4.nabble.com/Bioconductor-MA-plot-for-qPCR-array-tp4182805p4182805.html
Sent from the R help mailing list archive at Nabble.com.
2002 Jun 27
2
Fastest way to find the last index k such that x[k] < y in a sorted vector x?
Hi, I am trying to find the fastest way to
"find the last index k such that x[k] < y in a *sorted* vector x"
These are my two alternatives:
x <- sort(rnorm(1e4))
y <- 0.2
# Alt 1
k <- max(1, sum(x < y))
# Alt 2 "divide and conquer"
lastIndexLessThan <- function(x, y) {
k0 <- 1; k1 <- length(x)
while ((dk <- (k1 - k0)) >
2011 Dec 27
2
How to create a matrix with 3 dimensions from several 2 dimensional matrice?
Hi every one,
How is it possible to create a matrix with 3 dimensions from several 2
dimensional matrice?
Is it possible that each of "elementary/building block" matrices could be
called by its corresponding original name?
Thanks alot.
--
View this message in context:
2009 Jul 29
1
Which CRAN mirror is the fastest ?
Hi dear R help group.
I was wondering how can I find out which CRAN mirror would be the fastest
for me (I leave in Israel and therefore don't have a CRAN mirror for our
country to go to by default)
Thanks,
Tal
--
----------------------------------------------
My contact information:
Tal Galili
Phone number: 972-50-3373767
FaceBook: Tal Galili
My Blogs:
http://www.r-statistics.com/
2011 Aug 09
3
what is the fastest way to fetch results which are sorted by timestamp ?
what is the fastest way to fetch results which are sorted by timestamp ?
i want to use xapian as my search engine , use add_boolean_term(something) and add_value(0,sortable_serialise(get_timestamp())) to a doc.
search through enquire.set_weighting_scheme(xapian.BoolWeight()) and enquire.set_sort_by_value(0,True) to ensure that the results are sorted by the timestamp.
This method is ok , but
2007 Jun 24
3
Fastest Way to run Rails
Hi,
I am a bit confused about what is the fastest way to run a rails application.
I have seen examples which use Apache, mongrel, lighthttpd, fastcgi etc.
Is there a correct way to do it? Or is it just a personal choice?
Thanks,
Keith
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk"
2012 Mar 31
2
A introductory question about Zips law (Newbie to statistics)
Hi everyone.
Newbie to statistics.
I have 40 matrices of ~400 values. how may I determine whether the
distribution follows zips law?
response <-sample (1:20,400*4, replace= TRUE)
Thank you vry much.
--
View this message in context: http://r.789695.n4.nabble.com/A-introductory-question-about-Zips-law-Newbie-to-statistics-tp4521190p4521190.html
Sent from the R help mailing list archive at
2012 Mar 14
2
Apply a loop containing a function on a list
Hi all,
I want to do this:
B.list$aa= (a loop containing My.fun acting on the reults of second
function on a A.list$aa))
or, overally
B.list$aa = function (A.list$aa)
B.list and A.list has many sublists aa, ab and.... Is there a way I can
apply the function and loop on all sublists of A.list and get B.list?
Thanks in advance.
--
View this message in context:
2009 Oct 07
1
Which is fastest for Xen disks: LVM, Qcow2 or Image-based VM?
Is there any benchmark or does anyone have tried which one is fastest?
Regards,
--
Thiago Vinhas de Moraes
________________________________________________________
SimpleWeb Tecnologia Inovativa
Soluções em cloud computing e gerenciamento de TI
Av. das Américas, 500 - Bloco 23 / Sala 215
- Rio de Janeiro - RJ
Tel/Fax: 0800-8880-WEB / (21) 3002-0377
Celular: .(21)
2011 Jun 24
1
Fastest way of finding if any members of vector x fall in the range of the rows of matrix y
Hi All,
What is the fastest way of finding if any members of vector x fall in the
range of the rows of matrix y?
I do not want to use two for loops as this will take forever.
Any help will be appreciated,
best,
salih
[[alternative HTML version deleted]]
2005 Dec 14
2
The fastest way to select and execute a few selected functions inside a function
Dear useRs?
I have the following problem! I have a function that calls one or more
functions, depending on the input parameters. I am searching for the fastest
way to select and execute the selected functions and return their results in
a list. The number of possible functions is 10, however usually only 2 are
selected (although sometimes more, even all).
For examples, if I have function
2001 Aug 04
1
replacing elements in matrix: fastest method?
Hi!
I replace some elements of a matrix a
> a
[,1] [,2] [,3]
[1,] 1 2 3
[2,] 4 5 6
[3,] 7 8 9
[4,] 10 11 12
according to a reclassification matrix such
> pares
[,1] [,2]
[1,] 1 2
[2,] 5 6
[3,] 8 7
to get
> b
[,1] [,2] [,3]
[1,] 1 2 3
[2,] 4 5 6
[3,] 7 8 9
[4,] 10 11 12
As both a and
2006 Apr 06
8
Fastest learning path to RoR
hi!
with a 4GL background, wanting to learn RoR, what is the fastest
learning path i should take? should i go grab a RoR tutorial, and learn
Ruby along the way, or start with plain Ruby first?
thanks for any inputs!
2017 Jun 26
0
what is causing this problem ... (yum, fastest mirror)
Hello,
what is causing the following, and can someone give the solution which is
mentioned at https://access.redhat.com/articles/1320623
by the way: why are the "fastest" mirrors from other continent?
[root at host sysconfig]# yum clean all
Loaded plugins: fastestmirror, security
Cleaning repos: base epel extras updates
Cleaning up Everything
Cleaning up list of fastest mirrors
[root
2011 Oct 22
1
How to it a "loess curve" and obtain the equation in R?
Hi!
How can I fit a loess curve to an array (384 x 2).
How can I obtain the equation for thi fi?
Thanks in advance.
--
View this message in context: http://r.789695.n4.nabble.com/How-to-it-a-loess-curve-and-obtain-the-equation-in-R-tp3927622p3927622.html
Sent from the R help mailing list archive at Nabble.com.
2011 Aug 11
3
Fwd: Re: what is the fastest way to fetch results which are sorted by timestamp ?
(Forwarded off-list message)
-------- Original Message --------
Subject: Re: [Xapian-discuss] what is the fastest way to fetch results
which are sorted by timestamp ?
Date: Thu, 11 Aug 2011 01:06:36 +0800
From: ??? <panjunyong at gmail.com>
To: Tim Brody <tdb2 at ecs.soton.ac.uk>
On Wed, Aug 10, 2011 at 6:39 PM, Tim Brody <tdb2 at ecs.soton.ac.uk> wrote:
> Hi,
>
> In
2005 Aug 18
0
Which AGI Development Software is fastest onAsterisk?
What can you develop in? What are you comfortable? I use PHP for
testing
then convert into C shared objects.
..o-------------------------------------------------------o.
Brian Fertig
NOC/Network Engineer
Planet Telecom, Inc.
Tampa, FL Office
-----Original Message-----
From: asterisk-users-bounces@lists.digium.com
[mailto:asterisk-users-bounces@lists.digium.com] On Behalf Of Asterisk
Sent: