similar to: Bootstrap ICC estimate with nested data

Displaying 20 results from an estimated 300 matches similar to: "Bootstrap ICC estimate with nested data"

2010 Nov 06
2
3-way interaction simple slopes
Can anyone show me how to test for significant simple slopes of a 3-way interaction, with covariates. my equation tmod<-(glm(PCL~ rank.f + gender.f + MONTHS + CEXPOSE.M + bf.m + MONTHS*CEXPOSE.M*bf.m, data=mhatv, family=gaussian ,na.action=na.omit)) Thank you Mike [[alternative HTML version deleted]]
2017 Dec 14
1
match and new columns
Hi Bill, I put stringsAsFactors = FALSE still did not work. tdat <- read.table(textConnection("A B C Y A12 B03 C04 0.70 A23 B05 C06 0.05 A14 B06 C07 1.20 A25 A23 A12 3.51 A16 A25 A14 2,16"),header = TRUE ,stringsAsFactors = FALSE) tdat$D <- 0 tdat$E <- 0 tdat$D <- (ifelse(tdat$B %in% tdat$A, tdat$A[tdat$B], 0)) tdat$E <- (ifelse(tdat$B %in% tdat$A, tdat$A[tdat$C], 0))
2017 Dec 13
0
match and new columns
Hello, Here is one way. tdat$D <- ifelse(tdat$B %in% tdat$A, tdat$A[tdat$B], 0) tdat$E <- ifelse(tdat$B %in% tdat$A, tdat$A[tdat$C], 0) Hope this helps, Rui Barradas On 12/13/2017 9:36 PM, Val wrote: > Hi all, > > I have a data frame > tdat <- read.table(textConnection("A B C Y > A12 B03 C04 0.70 > A23 B05 C06 0.05 > A14 B06 C07 1.20 > A25 A23 A12 3.51
2017 Dec 14
0
match and new columns
Use the stringsAsFactors=FALSE argument to read.table when making your data.frame - factors are getting in your way here. Bill Dunlap TIBCO Software wdunlap tibco.com On Wed, Dec 13, 2017 at 3:02 PM, Val <valkremk at gmail.com> wrote: > Thank you Rui, > I did not get the desired result. Here is the output from your script > > A B C Y D E > 1 A12 B03 C04 0.70 0 0
2017 Dec 13
2
match and new columns
Thank you Rui, I did not get the desired result. Here is the output from your script A B C Y D E 1 A12 B03 C04 0.70 0 0 2 A23 B05 C06 0.05 0 0 3 A14 B06 C07 1.20 0 0 4 A25 A23 A12 3.51 1 1 5 A16 A25 A14 2,16 4 4 On Wed, Dec 13, 2017 at 4:36 PM, Rui Barradas <ruipbarradas at sapo.pt> wrote: > Hello, > > Here is one way. > > tdat$D <- ifelse(tdat$B %in% tdat$A,
2017 Dec 13
3
match and new columns
Hi all, I have a data frame tdat <- read.table(textConnection("A B C Y A12 B03 C04 0.70 A23 B05 C06 0.05 A14 B06 C07 1.20 A25 A23 A12 3.51 A16 A25 A14 2,16"),header = TRUE) I want match tdat$B with tdat$A and populate the column values of tdat$A ( col A and Col B) in the newly created columns (col D and col E). please find my attempt and the desired output below Desired output
2007 Dec 06
5
Help rewriting looping structure?
Hey Folks, Could somebody help me rewrite the following code? I am looping through all records across 5 fields to calculate the cumulative percentage of each record (relative to each individual field). Is there a way to rewrite it so I don't have to loop through each individual record? ##### tdat is my data frame ##### j is my field index ##### k is my record index ##### tsum is the sum of
2018 May 18
0
exclude
... and similar to Jim's suggestion but perhaps slightly simpler (or not!): > cross <- xtabs( Y ~ stat + year, data = tdat) > keep <- apply(cross, 1, all) > keep <- names(keep)[keep] > cross[keep,] year stat 2003 2004 2006 2007 2009 2010 AL 38 21 20 12 16 15 NY 50 51 57 98 183 230 > ## for counts just do: > xtabs( ~ stat + year, data
2018 May 18
1
exclude
Thank you Bert and Jim, Jim, FYI , I have an error message generated as Error in allstates : object 'allstates' not found Bert, it is working. However, If I want to chose to include only mos years example, 2003,2004,2007 and continue the analysis as before. Where should I define the years to get as follow. 2003 2004 2007 AL 2 1 1 NY 1 1 2 Thank you
2012 Apr 20
1
Ternaryplot as an inset graph
Hello I am trying to add a ternary plot as a corner inset graph to a larger main ternary plot. I have successfully used add.scatter in the past for different kinds of plots but It doesn't seem to work for this particular function. It overlays the old plot rather than plotting as an inset. Here is a simple version of what I'm trying. Note that if I change the inset plot to be an ordinary
2010 Nov 01
2
transforming a dataset for association analysis RESHAPE2
I get the following message when using the reshape2 package line > tDat.m<- melt(Dataset) Using Item, Subject as id variables > tDatCast<- acast(tDat.m,Subject~Item) Aggregation function missing: defaulting to length Note Problem Statement- convert dataframe Subject Item Score 1 Subject 1 Item 1 1 2 Subject 1 Item 2 0 3 Subject 1 Item 3 1 4 Subject 2 Item 1 1 5
2016 Apr 22
1
npudens(np) Error missing value where TRUE/FALSE needed
Hi, I am looking for some help concerning the npudens function in the np package. I am trying to find a kernel density function of a multivariate dataset and the density evaluated at each of the 176 points. I have 2 continuous and 3 ordered discrete variables. My sample size is 176. So edata is a 176x(2+3) data frame, while tdat is a 1x(2+3) vector. bw_cx[i,] is a 1x (2+3) vector
2018 Jan 22
2
How to address the following: CRAN packages not using Suggests conditionally
Re-sending, since I forgot to include the list, sorry. I'm including r-package-devel too this time, as it seems more appropriate for this list. El 22 ene. 2018 10:11, "I?aki ?car" <i.ucar86 at gmail.com> escribi?: > > > El 22 ene. 2018 8:12, "Ulrich Bodenhofer" <bodenhofer at bioinf.jku.at> > escribi?: > > Dear colleagues, dear members of
2007 Aug 11
1
xyplot() with segments() superposed?
In the hypothetical example below, how do I add two segments() into the two panels, respectively? Say segments(x0=5, y0=10, x1=5, y1=20) on the left and segments(x0=15, y0=-10, x1=15, y1=-2) on the right? Many thanks in advance, Yuelin Li. ps. part of the code came from a solution given by Deepayan Sarkar. ------------------- library(lattice) set.seed(12345) x <- 0:20 y.male.obs <- - 1.2
2018 May 18
3
exclude
Hi All, I have a sample of data set show as below. tdat <- read.table(textConnection("stat year Y AL 2003 25 AL 2003 13 AL 2004 21 AL 2006 20 AL 2007 12 AL 2009 16 AL 2010 15 FL 2006 63 FL 2007 14 FL 2007 25 FL 2009 64 FL 2009 47 FL 2010 48 NY 2003 50 NY 2004 51 NY 2006 57 NY 2007 62 NY 2007 36 NY 2009 87 NY 2009 96 NY 2010
2009 Jan 22
1
Problem with cex=0.1 when making jpegs
I am using the following script to make .jpg files. jpeg('plotx.jpg') ddat <-read.table("file",header=T) attach(ddat) tdat<-read.table("file1") plot(xx1,yy1,type='p',pch=1,col="blue",cex=0.2,xlim=c(0,3.5),ylim=c(-75,75)) points(tdat,col="green",pch=1,cex=0.2) dev.off() The problem is that I want the points to be very small;
2007 Oct 17
2
nmle: gnls freezes on difficult case
Hi, I am not sure this is a bug but I can repeat it, The functions and data are below. I know this is nasty data, and it is very questionable whether a 4pl model is appropriate, but it is data fed to an automated tool and I would have hoped for an error. Does this repeat for anyone else? My details: > version _ platform i686-pc-linux-gnu
2008 Oct 11
1
problem with cut.Date/date plotting in ggplot2
I've hit a problem in ggplot2 which I can trace back to cut.Date , which is either a bug or (??) ggplot2 trying to do something it shouldn't with cut.Date (although its use of cut.Date seems OK). Apparently any (?) call of the form cut(as.Date("2008-07-07"),"weeks") where the date *begins the week*, gives the error Error in 1:(1 + max(which(breaks < maxx))) :
2010 Nov 14
1
R package 'np' problems
Hi List, I'm trying to get a density estimate for a point of interest from an npudens object created for a sample of points. I'm working with 4 variables in total (3 continuous and 1 unordered discrete - the discrete variable is the character column in training.csv). When I try to evaluate the density for a point that was not used in the training dataset, and when I extract the fitted
2018 Jan 22
1
How to address the following: CRAN packages not using Suggests conditionally
On 01/22/2018 08:40 AM, Ulrich Bodenhofer wrote: > Thanks a lot, I?aki, this is a perfect solution! I already implemented > it and it works great. I'll wait for 2 more days before I submit the > revised package to CRAN - in order to give others to comment on it. It's very easy for 'pictures of code' (unevaluated code chunks in vignettes) to drift from the actual