similar to: merging multiple columns from two dataframes

Displaying 20 results from an estimated 300 matches similar to: "merging multiple columns from two dataframes"

2011 Aug 30
2
Error in evalauating a function
Hi, ? I am very new to R. So, pardon my dumb question. I was trying to write my own function to run a different model (perform an ordered logistic regression) using the example in website http://pngu.mgh.harvard.edu/~purcell/plink/rfunc.shtml But R returns a error `R Error in eval(expr, envir, enclos) : object 's' not found' when I run it. What am I doing wrong here? Here's
2006 Jul 23
1
Iterated Data Input/Output with Random Forests
Hi, I am currently writing code to input a few thousand files, run them through the Random Forests package, and then output corresponding results. When I use the code below: zz<-textConnection("ex.lm.out", "w") sink(zz)
2018 Apr 19
4
create multiple categorical variables in a data frame using a loop
Hi All, I want to create a categorical variable, cat.pfoa, in the file of pfas.pheno (a data frame) based on log2pfoa values. I can do it using the following code. pfas.pheno <-within(pfas.pheno, {cat.pfoa<-NA cat.pfoa[pfas.pheno$log2pfoa <=quantile(pfas.pheno$log2pfoa,0.25, na.rm =T)]<-0 cat.pfoa[pfas.pheno$log2pfoa >=quantile(pfas.pheno$log2pfoa,0.75, na.rm =T)]<-2
2018 Apr 19
0
create multiple categorical variables in a data frame using a loop
Hello, When programming it is better to use dat[["variable"]] than dat$variable. So your code could be pfas.pheno[[cat.var]] <- NA pfas.pheno[[cat.var]][pfas.pheno[,i] <= quantile(pfas.pheno[,i],0.25, na.rm =T)] <- 0 etc. Untested. Hope this helps, Rui Barradas On 4/19/2018 7:20 PM, Ding, Yuan Chun wrote: > Hi All, > > I want to create a categorical variable,
2018 Apr 19
0
create multiple categorical variables in a data frame using a loop
> On Apr 19, 2018, at 11:20 AM, Ding, Yuan Chun <ycding at coh.org> wrote: > > Hi All, > > I want to create a categorical variable, cat.pfoa, in the file of pfas.pheno (a data frame) based on log2pfoa values. I can do it using the following code. > > pfas.pheno <-within(pfas.pheno, {cat.pfoa<-NA > cat.pfoa[pfas.pheno$log2pfoa
2006 Sep 25
2
paste? 'cmd /c "c:\\pheno\\whap --file c:\\pheno\\smri --alt 1"'
Dear R users, This command works (calling a programm -called whap- with file specifiers etc.): >system('cmd /c "c:\\pheno\\whap --file c:\\pheno\\smri --alt 1 --perm 500"', intern=TRUE) Now I need to call it from a loop to replace the "1" by different number, however I get lost using the quotes: I tried numerous versions of: >i<-1
2010 Sep 24
1
color of lines while printing through for loop
I am trying to find a convenient way to control line colors when printing from a for loop using the lines command. Right now I have solved this by creating a colors vector that is refered to in the loop with index. However, the colors choosen here are just 1,2,3,4,5... I would like to get colors from the col = rainbow(x) that you can use in plot() and set the to be my number of lines (I think
2018 Apr 20
1
create multiple categorical variables in a data frame using a loop
> On Apr 19, 2018, at 1:22 PM, David Winsemius <dwinsemius at comcast.net> wrote: > > >> On Apr 19, 2018, at 11:20 AM, Ding, Yuan Chun <ycding at coh.org> wrote: >> >> Hi All, >> >> I want to create a categorical variable, cat.pfoa, in the file of pfas.pheno (a data frame) based on log2pfoa values. I can do it using the following code.
2010 May 06
5
Apologies : question on transforming a table
Dear R-help list, Apologies. I am trying to convert one table to another. It feels that it should be a very straightforward answer with a single (or two) commands with the right extensions, but I really can't figure this out right now. I have several hundred pheno factors actually, so manually doing this line by line is not an option. My original table is approximately like this : ID
2008 May 13
1
R help: problems with step function
Dear List Members, I have encountered two problems when using the step function to select models. To better illustrate the problems, attached is an R image which includes the objects needed to run the code attached. lm.data.frame have factor variables with 3 levels. The following run shows the first problem. AICs (* and **) are different. I noticed that the Df for rs13482096:rs13483699 is 4,
2008 Feb 01
2
pheno package (PR#10674)
Full_Name: Anja Eggert Version: 2.4.1 OS: Submission from: (NULL) (139.30.70.203) I want to install the pheno package. This is not working. What can I do? Thank you very much, Anja
2010 Apr 29
1
R CMD check Error after R CMD build for R-2.11.0
Dear UseR, I get an error when I run "R CMD check" on my .tar.gz file package, and I don't understand why since I don't obtain any error with "R CMD check" on the package directory. Do you have any idea ? $ sudo ./R-2.11.0/bin/R CMD check eqtl_1.1.tar.gz and $ sudo ./R-2.11.0/bin/R CMD --check-subdirs=no eqtl_1.1.tar.gz return an Error * checking for working
2011 Dec 08
1
Ultra Xfinity 1500VA UPS
>>>>>>>>>>>>>>><<<<<<<<<<<<<<<< Pheno-Mint upsmon # /sbin/upsdrvctl start Network UPS Tools - UPS driver controller 2.6.1 Network UPS Tools - Generic HID driver 0.35 (2.6.1) USB communication driver 0.31 This PowerCOM device (0d9f:0004) is not (or perhaps not yet) supported by usbhid-ups. Please make sure
2023 Mar 30
1
seqMK function
Hello does anyone know how to set the confidence level within the seqMK() function in the pheno package. It seems to be set automatically at 0.05 and there seems to be neither an input function to set a different level, as there are with some changepoint functions, nor an output to give one the p-value of the changepoint identification which you get with functions ie func$p_value etc ... Thanks
2003 Sep 24
1
64-bit Oracle interface
Hi, I am running the 64bit version of R on a AIX RS6000 cluster on which is also running the ' SQL*Plus: Release 9.2.0.2.0' in the 'ORACLE-environment Version 64 bit AIX 5.1'. I have problems setting up an Oralce database connection. I can instantiate a driver using drv <- Oracle(). But when I try to connect to my database using dbConnect (dbConnect(drv,
2023 Apr 01
1
weird things in seqMK() and sqmk()
Hello The other say I posted a question about altering confidence limits in the seqMK() function in the pheno package. I didn't get any bites but in any case I've been trying to use this function. It seems to me to give very odd results - sometimes identifying 8 or 9 changepoints in a relatively short vector of maybe 40 elements, and at other times not giving any changepoints at all,
2010 Mar 04
6
help
Hi all , I have one query. i have list of some .cel files. in my program i have to mention the path of these .cel files part of my program is, rna.data<-exprs(justRMA(filenames=file.names, celfile.path=*datadir*, sampleNames=sample.names, phenoData=pheno.data, cdfname=cleancdfname(hg18_Affymetrix U133A))) in the place of "datadir" i have to mention the character string of the
2009 Oct 12
2
R commander.
i have two RData files,,i want to print them to check the format of the tables in these files,,,i can load both the files and can read it as well > load('ann.RData') > str(ann) List of 4 $ Name : chr [1:561466] "rs3094315" "rs12562034" "rs3934834" "rs9442372" ... $ Position : int [1:561466] 742429 758311 995669 1008567 1011278 1011521
2006 Aug 18
0
[Fwd: Trend test and test for homogeneity of odd-ratios]
I partly answered my question since independence_test() function in coin package apparently do Cochran-Armitage trend test just like Eric Lecoutre's function tabletrend() - slightly modified here: > independence_test(pheno ~ geno, data = dat2, teststat = "quad", scores = list(geno = c(0, 1, 2))) Asymptotic General Independence Test data: pheno by groups 1 < 2
2011 Oct 10
4
correlation matrix
Hello Gurus I have two correlation matrices 'xa' and 'xb' set.seed(100) d=cbind(x=rnorm(20)+1, x1=rnorm(20)+1, x2=rnorm(20)+1) d1=cbind(x=rnorm(20)+2, x1=rnorm(20)+2, x2=rnorm(20)+2) xa=cor(d,use='complete') xb=cor(d1,use='complete') I want to combine these two to get a third matrix which should have half values from 'xa' and half