search for: random1

Displaying 7 results from an estimated 7 matches for "random1".

Did you mean: random
2008 Nov 19
1
F-Tests in generalized linear mixed models (GLMM)
...anyone konw why, or how to fix the problem? To illustrate the problem, I send the output of a simulated example. Thank you very much in advance. Best regards, Bj?rn Example: > # simulation of data > n <- 300 > x1 <- sample(c(T,F), n, replace=TRUE) > x2 <- rnorm(n) > random1 <- sample(c("level1","level2","level3"), n, replace=TRUE) > true.lp <- 5 + 1.1*x1 + 0.16 * x2 > mu <- exp(true.lp) > sigma <- mu * 1 > a <- mu^2/sigma^2 > s <- sigma^2/mu > y <- rgamma(n, shape=a, scale=s) > > librar...
2010 Jul 08
2
random sample from arrays
...-sample(x,50) print(c(i,"->", set), quote = FALSE) } which basically do the trick, but I just can't save the results outside the loop. After having the random sets of lines it wasn't a problem to extract the line from the arrays using subset. genSet1 <-sample(x,50) random1 <- genes %in% genSet1 subsetGenelist <- subset(genelist, random1) is there a different way of creating these random vectors or saving the loop results outside tjhe loop so I cn work with them? Thanks a lot Assa [[alternative HTML version deleted]]
2004 Oct 28
2
array problem and for looping
An embedded and charset-unspecified text was scrubbed... Name: not available Url: https://stat.ethz.ch/pipermail/r-help/attachments/20041028/dbf887a9/attachment.pl -------------- next part -------------- An embedded and charset-unspecified text was scrubbed... Name: random1.txt Url: https://stat.ethz.ch/pipermail/r-help/attachments/20041028/dbf887a9/random1.txt
2011 Dec 02
0
Save Venn-diagram (Vennerable) together with table and plot in single pdf page
...,heights=c(1,1,2)) par(mar=c(6,2,2,4)) textplot(tabletext,valign="top",halign="left",cex=2) plot(rnorm(100),main="Random 1") plot(rnorm(100),col="red",main="Random2") dev.off() And here the example of the pdf with where I try to replace the "Random1" point plot with a Venn diagram (wrong size and position of Venn diagram): pdf("path/venn_test.pdf", fillOddEven=TRUE,paper="a4", onefile=TRUE,width=7,height=10) layout(matrix(c(1,2,2,1,2,2,3,3,3), 3, 3, byrow = TRUE),heights=c(1,1,2)) par(mar=c(6,2,2,4)) textplot(tablet...
2011 Dec 23
1
Long jobs completing without output
...for on-line help, or 'help.start()' for an HTML browser interface to help. Type 'q()' to quit R. > library(arm) arm (Version 1.4-13, built: 2011-6-19) Working directory is /home/brendan/work/mlmmarks/genderECSR > library(foreign) > mlm <- read.dta("../worksample-random1.dta") > attach(mlm) > > gender <- as.factor(stu_gend) > > yr <- year - 1998 > failure <- (lmer(fail ~ + 1 + cao + subj1 + subj2 + subj3 + gender + yr + ageentry + as.factor(yrs5) + + modsize + meancao + depfemr + (1|deptno) + (1|modin...
2012 May 09
2
Random resampling of columns in species association matrices
I have a host-parasite association matrix in which parasite species are rows and host species columns and cells contain the frequency of interactions. Some parasites are associated with many hosts, and some hosts harbor several parasites, and I want to repeatedly select only one single representative host per "generalized" (multi-host) parasite to create a new matrix in which no hosts
2009 Feb 09
11
Choosing a random number between x and y
Hi, Ive been trying to find a function that will allow me to pull out a number between a minimum and maximum threshold. I want a random decimal number between, for example, 0 and 0.5 or 0 and 0.7. I've been searching everywhere for a function that will allow me to do this in R, but I have yet to be successful. Any help would be much appreciated. Thanks in advance -- View this message in