similar to: add vectors to multiple objects

Displaying 20 results from an estimated 3000 matches similar to: "add vectors to multiple objects"

2012 Aug 01
2
assign vectors to objects
Hi everyone, I try to add many vectors (L1,L2,L3....) to multiple list objects (a.list, b.list....) in a workspace. Somethings like below, but it is not working. Any suggestions will be appreciated. Best, John lf=ls(pattern=".lst")  for (x in listfiles) {     dat=read.delim(x,header=F)     for (i in lf) {     assign(i$add,as.numeric(dat[,3]))   #or i$add=as.numeric(dat[,3]    
2005 Nov 27
2
'For each file in folder F do....'
Hello, I have 2700 text files in a folder and need to apply the same program/procedure to each individually. I'm trying to find how to code something like: For each file in <Folder> do {<Procedure>} is there an easy way to do this? other suggestions? I have tried to list all the files names in a vector e.g. >listfiles[1:10,1] 1 H:/Rtest/AXP.txt 2 H:/Rtest/BA.txt 3
2009 Jul 01
1
Average of data files in a directory
Dear all, I know it is as simple as c <- (a + b)/2 to compute the average (element-wise) of two data vectors. However, I can't work out to compute the average when you have many data vectors in a directory. I have done this: ------------------------------------ setwd("/.../data/") listfiles <- list.files(pattern=".pre") # list all datafiles in the directory
2006 Jul 12
6
Copying Records
This might seem like a silly quesiton but it''s been baffling me all day! I want to copy all records matching certain criteria from table A to table B. I know how to do his with SQL but not with RoR. -- Posted via http://www.ruby-forum.com/.
2019 Jul 02
1
eliminate a partial argument match warning in R CMD check
Hello, I'm seeing a nuisance warning when I run `R CMD check --as-cran whatever_x.y.z.tar.gz`. I generally work with these options set: options( warnPartialMatchArgs = TRUE, warnPartialMatchAttr = TRUE, warnPartialMatchDollar = TRUE ) And I see this: * checking use of SHLIB_OPENMP_*FLAGS in Makefiles ...Warning in dir("src", patt = "[.]c$") : partial argument
2008 Oct 07
3
vectorized sub, gsub, grep, etc.
R pattern-matching and replacement functions are vectorized: they can operate on vectors of targets. However, they can only use one pattern and replacement. Here is code to apply a different pattern and replacement for every target. My question: can it be done better? sub2 <- function(pattern, replacement, x) { len <- length(x) if (length(pattern) == 1) pattern <-
2014 Apr 28
2
Re: [supermin] Be smarter about finding suitable kernel images
* Richard W.M. Jones: > On Sat, Apr 26, 2014 at 02:27:07PM +0200, Hilko Bengen wrote: >> --- >> src/kernel.ml | 43 ++++++++++++++++++++++++++++--------------- >> 1 file changed, 28 insertions(+), 15 deletions(-) >> >> diff --git a/src/kernel.ml b/src/kernel.ml >> index ed5aea3..436b1b0 100644 >> --- a/src/kernel.ml >> +++ b/src/kernel.ml
2016 Feb 26
5
Anyone know whats up with wiki?
> Anyway, Wiki is operational, but Dear List: Please report surprises. 1_ At the bottom-center, of each wiki page, there used to be a: "This page has been accessed 'N' times." message, in which 'N' was a number that (I think) comes from setting: $wgDisableCounters = true; Additionally, there used to be a "Special:PopularPages" page, available as an
2014 Apr 26
2
[supermin] Be smarter about finding suitable kernel images
--- src/kernel.ml | 43 ++++++++++++++++++++++++++++--------------- 1 file changed, 28 insertions(+), 15 deletions(-) diff --git a/src/kernel.ml b/src/kernel.ml index ed5aea3..436b1b0 100644 --- a/src/kernel.ml +++ b/src/kernel.ml @@ -23,6 +23,19 @@ open Utils open Ext2fs open Fnmatch +let patt_of_cpu host_cpu = + let models = + match host_cpu with + | "mips" |
2017 Sep 20
4
[PATCH 0/4] Replace some uses of the Str module with PCRE.
Str is a pretty ugly regexp module. Let's try to replace it with PCRE. This series of commits goes some small way towards that eventual goal. - - - I wonder if there was a deep reason why we had this? let unix2dos s = String.concat "\r\n" (Str.split_delim (Str.regexp_string "\n") s) I replaced it with what I think should be (nearly) equivalent: let unix2dos s =
2017 Sep 22
27
[PATCH v3 00/22] Replace almost all uses of the Str module with PCRE.
v1: https://www.redhat.com/archives/libguestfs/2017-September/msg00135.html v2: https://www.redhat.com/archives/libguestfs/2017-September/msg00158.html v3 is almost identical to v2, but I have added 4 extra commits to almost finish the job of replacing Str everywhere possible (note it's not possible to replace Str in common/mlstdutils or the generator because those are pure OCaml). As
2008 Feb 26
2
Combining series of variables using identifier
R users, I have df like this a <- data.frame( indx = 1:20, var1 = rep(c("I20", "I40", "A50", "B60"), each=5), var1_lab= rep(c("cat", "dog", "mouse", "horse"), each=5), var2 = rep(c("B20", "X40", "D50",
2010 Jan 04
3
vectors into a matrix
Dear all, I'm writing code to do automatically several calculations and gather the results in a matrix. I have the following vectors and I just want to make a matrix with them: VD1 VD2 VD3 ... VD12 *In this case, this series of vectors stops there, in 12, but it could be a higher number or smaller. (for example: VD1, VD2 and VD3; only) (or for example: VD1, VD2, ... till VD78) All
2012 Aug 25
3
Sysvol Replication in Samba4
Hi, We installed a samba4 AD controller using Gpo for a small group of users (5 users), everything is OK. (Samba4 beta 7 on Ubuntu 12.04) We installed another Samba4 AD controller as a BDC of the first one with the command "samba-tool domain join" with succes. After checking this new installation, we saw that the sysvol share was not replicated from the PDC and all the Policies are
2010 Sep 08
2
subbing a string vector for another string vector
I have a data frame with two columns: image pattern 1 http://$IMAGE_ID$ www.url.com/image.jpg 2 $IMAGE_ID$ http://www.blah.com/image.gif ... I want to replace "$IMAGE_ID$" with the corresponding entry in the pattern column such that the result would appear as follows: url http://www.url.com/image.jpg
2007 Nov 13
2
cbind function
Hello everyone, I would like to use the "cbind" function to construct a dataset, combining some variable I defined before. The codes are something like var1 <- ... var2 <- ... var2 <- ... ... data <- cbind(var1,var2,var3...) The problem is I would like some flexibity in the data, i.e. the number of the variables are not fixed. Is there a method of combine the uncertain
2008 Mar 02
1
summarizing matrix data
Hi everyone, I'm sure this is simple, but I can't seem to figure this out. Situation. 3 different groups of subjects each submit n X n matrices of scores. What I want to do is aggregate each group of scores into a summary n X n matrix. I need the result to be a matrix so that I can calculate a dissimilarity structure on it. So I thought I would create a multi-dimensional array and
2010 Mar 11
2
[PATCH FOR DISCUSSION ONLY] Rewrite libguestfs-supermin-helper in C.
This needs loads more testing before we include it. However it's in good shape for testing and review. Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones virt-df lists disk usage of guests without needing to install any software inside the virtual machine. Supports Linux and Windows. http://et.redhat.com/~rjones/virt-df/ -------------- next part
2017 Sep 21
18
[PATCH v2 00/18] Replace many more uses of the Str module with PCRE.
v1 was here: https://www.redhat.com/archives/libguestfs/2017-September/msg00135.html This is a more complete evolution of the earlier patch. It replaces most important uses of Str with PCRE throughout the code. It also extends the bindings with some useful features like case-insensitive regexps. The main places I *didn't* touch are the generator (GObject uses Str extensively); and
2011 May 17
3
gsub() issue...
Un texte encapsul? et encod? dans un jeu de caract?res inconnu a ?t? nettoy?... Nom : non disponible URL : <https://stat.ethz.ch/pipermail/r-help/attachments/20110517/1812d6c6/attachment.pl>