Re: [R] Populate one data frame with values from another dataframe for rows that match

2017-10-13 Thread Kevin Wamae
Dear @Rui Barradas, thank you for the solution. It works perfectly. On 13/10/2017, 23:35, "Rui Barradas" wrote: Hello, Try the following. myDF1$studyno <- as.character(myDF1$studyno) myDF2$studyno <- as.character(myDF2$studyno) i1 <- which(names(myDF1) == "pf_

Re: [R] Populate one data frame with values from another dataframe for rows that match

2017-10-13 Thread Kevin Wamae
Dear @Bert Gunter, I tried merge and I faced many challenges. @Rui Barradas solution is working. From: Bert Gunter Date: Friday, 13 October 2017 at 22:44 To: Kevin Wamae Cc: R-help Subject: Re: [R] Populate one data frame with values

[R] make check Error: could not get timezone

2017-10-13 Thread Stephen Berman
I just built the latest R-patched from source (SVN-Revision: 73548, Last Changed Date: 2017-10-12) and the build completed without a problem but `make check' errored out: running code in 'reg-tests-1d.R' ...make[3]: *** [Makefile.common:100: reg-tests-1d.Rout] Error 1 make[3]: Leaving directo

Re: [R] How to define proper breaks in RFM analysis

2017-10-13 Thread Jim Lemon
Hemant's problem is that the indicators are not distributed uniformly. With a uniform distribution, categorization gives a reasonably optimal separation of cases. One approach would be to drop categorization and calculate the overall score as the mean of the standardized indicator scores. Whether t

Re: [R] Populate one data frame with values from another dataframe for rows that match

2017-10-13 Thread Rui Barradas
Hello, Try the following. myDF1$studyno <- as.character(myDF1$studyno) myDF2$studyno <- as.character(myDF2$studyno) i1 <- which(names(myDF1) == "pf_mcl") merge(myDF1[-i1], myDF2, by = "studyno") Hope this helps, Rui Barradas Em 13-10-2017 20:09, Kevin Wamae escreveu: I'm trying to populat

Re: [R] Populate one data frame with values from another dataframe for rows that match

2017-10-13 Thread Bert Gunter
?merge Bert On Oct 13, 2017 12:09 PM, "Kevin Wamae" wrote: > I'm trying to populate the column “pf_mcl” in myDF1 with values from > myDF2, where rows match based on column "studyno" but the solutions I have > found so far don't seem to be giving me the desired output. > > Below is a snapshot of

Re: [R] Information

2017-10-13 Thread Bert Gunter
No. This is not a statistical consulting service. -- Bert On Oct 13, 2017 10:56 AM, "Sabrina Abdelghani" wrote: Hello, Can you help me about the R function to estimate Vector Autoregressive (VAR) model allowing fot the GARCH effet : VAR-DCC-GARCH model please.

Re: [R] Model within subjects treatment variable and multiple measurements per treatment: is this the correct model?

2017-10-13 Thread Bert Gunter
Post on r-sig-mixed-models, not here. In PLAIN TEXT NOT HTML. -- Bert On Oct 13, 2017 10:55 AM, "Nynke l" wrote: > Hello all, > > > I have a question regarding my analysis and how to correctly model this in > r syntax. > > I have a dataset from an experiment in which each subject received 3 >

[R] Populate one data frame with values from another dataframe for rows that match

2017-10-13 Thread Kevin Wamae
I'm trying to populate the column “pf_mcl” in myDF1 with values from myDF2, where rows match based on column "studyno" but the solutions I have found so far don't seem to be giving me the desired output. Below is a snapshot of the data.frames. myDF1 <- structure(list(studyno = c("J1000/9", "J10

Re: [R] data.matrix output is not numeric

2017-10-13 Thread Richard M. Heiberger
integer is a subclass of numeric. > is.numeric(data.matrix(test.df)[[1]]) [1] TRUE See ?integer, ?numeric, ?storage.mode On Fri, Oct 13, 2017 at 2:07 PM, Ed Siefker wrote: > I have a data frame full of integer values. I need a matrix full of > numeric values. > > ?data.matrix reads: > >

[R] data.matrix output is not numeric

2017-10-13 Thread Ed Siefker
I have a data frame full of integer values. I need a matrix full of numeric values. ?data.matrix reads: Return the matrix obtained by converting all the variables in a data frame to numeric mode and then binding them together as the columns of a matrix. This does not work. test.

[R] Information

2017-10-13 Thread Sabrina Abdelghani
Hello, Can you help me about the R function to estimate Vector Autoregressive (VAR) model allowing fot the GARCH effet : VAR-DCC-GARCH model please. Garanti sans virus. www.avg.com

Re: [R] How to define proper breaks in RFM analysis

2017-10-13 Thread David Winsemius
> On Oct 13, 2017, at 2:51 AM, PIKAL Petr wrote: > > Hi > > You expect us to solve your problem but you ignore advice already recieved. > > Your data are unreadable, use dput(yourdata) instead. see ?dput > >> test<-read.table("clipboard", heade=T) > Error in scan(file = file, what = what, sep

Re: [R] Quotation marks hinder for loop

2017-10-13 Thread David Winsemius
> On Oct 13, 2017, at 6:50 AM, y tanaka wrote: > > Dear mailing list members, > > My question is maybe very basic, but I could not find the solution. > > I would like to do the following things > > 1) > colnames(V1)[2] <- par$V2[1] > colnames(V2)[2] <- par$V2[2] > colnames(V3)[2] <- par$V2[3]

[R] Quotation marks hinder for loop

2017-10-13 Thread y tanaka
Dear mailing list members, My question is maybe very basic, but I could not find the solution. I would like to do the following things 1) colnames(V1)[2] <- par$V2[1] colnames(V2)[2] <- par$V2[2] colnames(V3)[2] <- par$V2[3] ... colnames(V37)[2] <- par$V2[37] 2) V1 <- V1[,-1] V2 <- V2[,-1] V3 <

Re: [R] How to define proper breaks in RFM analysis

2017-10-13 Thread PIKAL Petr
Hi You expect us to solve your problem but you ignore advice already recieved. Your data are unreadable, use dput(yourdata) instead. see ?dput > test<-read.table("clipboard", heade=T) Error in scan(file = file, what = what, sep = sep, quote = quote, dec = dec, : line 115 did not have 6 elemen

Re: [R] How to define proper breaks in RFM analysis

2017-10-13 Thread Hemant Sain
Hey, i want to define 3 ideal breaks (bin) for each variable one of those variables is attached in the previous email, i don't want to consider quartile method because quartile is not working ideally for that data set because data distribution is non normal. so i want you to suggest another method

Re: [R] comparing two strings from data

2017-10-13 Thread Jeff Newmiller
data_2 <- read.csv("excel_data.csv",stringsAsFactors=FALSE) column_1 <- data_2$data1 column_2 <- data_2$data2 result <- match( column_1, column_2 ) Please read the Posting Guide mentioned at the bottom of this and every posting, in particular about posting plain text so that what we see will be