similar to: sequential row selection in dataframe

Displaying 20 results from an estimated 5000 matches similar to: "sequential row selection in dataframe"

2012 Feb 14
1
sequential sum
Dear R users, I am trying to sum number that exist in another vector up to i, then increment i and repeat. Sorry. It's hard to explain but basically I am trying to do the following: test <- c(1,2,3,4); test2 <- c(3,5,6,7,2,8,8,4,4); test3 <- c(10,20,30,40); tmp <- 0; for (i in 1:length(test)){ tmp[i] <- sum(test3[which(test[1:i] %in% test2)]); } so when i = 1, tmp[i] = 0
2006 Dec 26
1
Colored Dendrogram
Hi all, I am a real novice to R. :) I am struggling with a problem for generating colored dendrogram. I have searched the R list and complied/collected a R code which can generated a colored dendrogram based on the rainbow color and 4x4 similarity matrix (say matrix:m). In this dendrogram, each leaf is colored differently. But, I do not want the leaf colored on a random basis. I want to assign
2007 Sep 14
2
Problems with quota dict in 1.1.alpha4
Hello, there are problems with quota dict when multiple dovecot deliver processes are launched in parallel. It can be reproduced by sending a mail with multiple different recipients - the mail is delivered OK to all recipients, but the quota are not updated correctly in sql. I looked at the code and it seems that the problem is somewhere in dict cache. If I configure in Postfix max number of
2010 Jun 03
4
data-management: Rowwise NA
Dear R´ers.. In this mock dataset how can I generate a logical variable based on whether just tes or tes3 are NA in each row?? test<-sample(c("A",NA,"B"),100,replace=T) test2<-sample(c("A",NA,"B"),100,replace=T) test3<-sample(c("A",NA,"B"),100,replace=T) tes<-cbind(test,test2,test3)
2020 Mar 10
4
R CMD INSTALL cannot recognize full path on Windows
Oops, I think both of us forget to cite the r-devel channel. Best, Jiefei On Tue, Mar 10, 2020 at 5:13 AM Wang Jiefei <szwjf08 at gmail.com> wrote: > Thanks for your quick response, Tomas. > > Yes, this is a path issue, I think the problem is related to R, not the > Rtools make. I built an example package for reproducing the problem: > https://github.com/Jiefei-Wang/example
2013 Mar 26
3
Samba + ACLs: Can’t add group write permissions
Hi there, I?ve been trying to get my head around a problem I have with Samba. I?ve set up Samba 3.6.13 on a Raspberry Pi with Arch Linux ARM on it and let it serve a couple of folders from an attached external ext4 drive mounted to /srv/cifs (of course with the "acl" option enabled). I?ve been trying to create a share that is read-writable for all members of a particular UNIX user
2011 Dec 05
1
Subsetting a data frame
Hi R users, I really need help with subsetting data frames: I have a large database of medical records and I want to be able to match patterns from a list of search terms . I've used this simplified data frame in a previous example: db <- structure(list(ind = c("ind1", "ind2", "ind3", "ind4"), test1 = c(1, 2, 1.3, 3), test2 = c(56L, 27L, 58L,
2015 Jun 02
2
preallocation=full Vs preallocation=metadata
Hi All I was reading through this: http://kashyapc.com/2011/12/02/little-more-disk-io-perf-improvement-with-fallocateing-a-qcow2-disk/ I was basically searching for pointers on improving disk I/O. I wanted to know the purpose of preallocation=full & preallocation=metadata , What is the difference between them ? and which one would yield a better disk I/O speed ? Appreciate your
2009 May 07
1
paste with apply, spaces and NA
Hello everyone, I've come up with a problem with using paste() inside apply() that I can't seem to solve. Briefly, if I'm using paste to collapse the rows of a data frame, AND the data frame contains strings with spaces, AND there are NA values in subsequent columns, then paste() introduces spaces. This only happens with that particular combination of data values and commands. I have
2009 Aug 27
1
select one function from two of them in another function
Hi all, I have two functions called test1() and test2(). Now how do I select one of them in test3()?? Say test3<-function(func="test1"){ if (func=="test1"){ now.func<-test1() } else now.func<-test2() } I know this function I wrote does not right. Do anyone can tell me how to do that for real? Thanks a million S.H. --
2008 Apr 09
2
problem with basic boolean selection in sequence
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/20080409/28fc5778/attachment.pl
2007 May 15
2
Anova Test
Hi, I am very new to R. I am trying to perform an Anova Test and see if it differs or not. Basically, i have 4 tests and 1 control. Tester Test1 Test2 Test3 Test4 Control 20 25 15 10 17 The inference is at alpha=0.05. they are all independent. I am trying to find if they differ or the same. > test1<-c(20) > test2<-c(25) > test3<-c(15) >
2004 Aug 25
2
asterisk & chan_sccp
ive got asterisk running with chan_sccp and three cisco phones (2 7910's and 1 7960). lots of bugs. when i press the speed dial button on either 7910, asterisk dies. also, if i dial from the 7910 to 7910, everything works fine. i can dial from or to the 7960 once, and then one of the 10's and the 60 die and try to reregister. if i take the 7960 out of the mix and remove its
2006 Mar 31
4
javascript help
Hi list, I have a list of tags. I want to be able to click on a tag and have that tag name populate an input field. I think delicious used to allow you to click on existing links to tag your bookmark similar to this (moving instead to auto_complete). My guess is the code looks something like this.... <form> <input type="text" name="all" id="discover"
2003 Aug 03
3
Include-from ?
Hello - I just finished doing a search of the archives and couldn't seem to get this answered. Example, I have a root directory containing the following directories: /Test1 /Test2 /Test3 I want to rsync only /Test2 and all subdirs under. So my include-from file looks like: + Test2/* - /* This doesn't work as nothing is synced, and if I do a -vv it tells me that nothing is being
2008 Jan 29
2
how do i creat multiple back to back histograms?
Een ingesloten tekst met niet-gespecificeerde tekenset is van het bericht gescrubt ... Naam: niet beschikbaar Url: https://stat.ethz.ch/pipermail/r-help/attachments/20080129/23f6cbc7/attachment.asc
2008 Apr 25
1
samba and openldap authentication issues!
Alight, I've been working on this for too many hours straight. Any help would be much appreciated! (I posted this online to linux questions, it could be easier to read on there... http://www.linuxquestions.org/questions/linux-server-73/samba-and-openldap-authentication-issues-637647/) The problem is users created in smbldap-useradd can not login, unless they also are a local user. for
2008 Nov 23
3
grep for asterisks "*"'s
Hello, I'm trying to determine if a string contains asterisks using the grep function. I know that this is slightly difficult because * is a special character in regular expressions and needs to be escaped. However, escaping the * using \ doesn't work either: if(grep("\*", model)>0) #does the model have an interaction { do something... } produces the following error
2010 Jan 29
2
question about transpose
Hi all, if I transpose a matrix with t(data), the newly created colums do not appear to have the first row as header. How can I do to have all the newly created columns have their first row as a header? Thanks Gabriele Zoppoli, MD Ph.D. Fellow, Experimental and Clinical Oncology and Hematology, University of Genova, Genova, Italy Guest Researcher, LMP, NCI, NIH, Bethesda MD Work: 301-451-8575
2014 Nov 21
13
[PATCH 0/6] btrfs support part1: subvolume commands
Hi, This is the part1 of improving btrfs support. This series adds missing parameters to btrfs_subvolume_snapshot and btrfs_subvolume_create, and adds two new API btrfs_subvolume_get_default and btrfs_subvolume_show. Other parts will follow. Regards, Hu Hu Tao (6): btrfs: correct words about subvolume and snapshot btrfs: add optional parameter `ro' to btrfs_subvolume_snapshot btrfs: