similar to: Generating Interaction Factors (combinations of Data Frame columns)

Displaying 20 results from an estimated 4000 matches similar to: "Generating Interaction Factors (combinations of Data Frame columns)"

2006 Jan 20
3
fractional factorial design in R
Hi, i need to create a fractional factorial design sufficient to estimate the main effects. The factors may have any number of levels, let's say any number from 2 to 6. I've tried to use the library conf.design , but i cannot figure out how to write the code. For example, what is the code for a design with 5 factors (2x3x3x5x2) and only main effects not confounded? thanks in advance!
2010 Jun 24
1
BBH2 and FrF2 packages
Hi R HELP, I consider the 2^3 factorial experiment described at page 177 of the book Statistics for Experimenters: Design, Innovation, and Discovery by George E. P. Box, J. Stuart Hunter, William G. Hunter (BHH2). This example use the following data in file BHH2-Data/tab0502.dat at ftp://ftp.wiley.com/ in /sci_tech_med/statistics_experimenters/BHH2-Data.zip run T C K y 1 1 -1 -1 -1 60 2
2010 Jun 14
2
Which is the easiest (most elegant) way to force "aov" to treat numerical variables as categorical ?
Hi R help, Hi R help, Which is the easiest (most elegant) way to force "aov" to treat numerical variables as categorical ? Sincerely, Andrea Bernasconi DG PROBLEM EXAMPLE I consider the latin squares example described at page 157 of the book: Statistics for Experimenters: Design, Innovation, and Discovery by George E. P. Box, J. Stuart Hunter, William G. Hunter. This example use
2008 Oct 24
1
How to embed residual dot plots of BHH2::anovaPlot(...) into plotMeans(...)?
Dear R fans, I am preparing a lecture discussing the paper of Wilkinson and APA Task Force on Statistical Inference (1999, American Psychologist, 54, 594-604.) I'd like to demo their Figure 3B (p. 602) with R. That is to add plotMeans(...) with dots of BHH2::dotPlot(...) . Is there any elegant script to do the job? Thanks --------------- LI, Xiaoxu
2010 Feb 18
3
Can R make an usual dotplot
Dear R experts, Can R make an usual dotplot just like Minitab and other softwares? I have the following data, and can use dotchart to graph a dotplot: y=c(2.873438152e-01, -8.732895642e-01, 4.579001889e-01, 1.047395204e+00, 8.491182299e-02 , -1.938007105e+00, -1.273708343e+00, 9.848010588e-05, 7.238490734e-01, -1.490552717e+00) dotchart(y, xlab="10 observations from
2009 Nov 09
1
Quickly generate all possible combinations of 2 groups
Hi all, I suspect the answer to this query will be the tongue-in-cheek "use a quantum computer", but I thought my understanding might be sufficiently limited that I'm missing a simpler option. I'm looking for a way to cycle through all possible combinations of 2 groups of data. For 10 data points, that's 2^10 combinations, for 20 data points it's 2^20, etc. combn() from
2006 May 08
3
Non repetitive permutations/combinations of elements
Hello all, I am trying to create a matrix of 1s and -1s without any repetitions for a specified number of columns. e.g. 1s and -1s for 3 columns can be done uniquely in 2^3 ways. -1 -1 -1 -1 -1 1 -1 1 -1 -1 1 1 1 -1 -1 1 -1 1 1 1 -1 1 1 1 and for 4 columns in 2^4 ways and so on. I finally used the function combn([0 1],3) that I found at the following link
2006 May 09
1
combn(n, k, ...) and all its re-inventions
It seems people are reinventing the wheel here: The goal is to generate all combinations of 1:n of size k. This (typically) results in a matrix of size k * choose(n,k) i.e. needs O(n ^ k) space, hence is only applicable to relatively small k. Then alternatives have been devised to generate the combinations "one by one", and I think I remember there has been a quiz/challenge about 20
2006 Dec 10
3
DOE teaching suggestions?
Dear R People: I will be teaching an undergraduate Design of Experiments class in the Spring Semester. It will be very much an applied course. My question, please: has anyone used R for a course like this, please? I've tried Rcmdr for a regression course and just plain command line for a time series course. Should I use Rcmdr, or teach them to use the command line, OR is there something
2007 Mar 26
1
Problem in loading all packages all at once
Hi All Please see the Rprofile file which i have modified as follows and after that when I start R then I see that R says to me "TRUE" for all the packages implying that all loaded at once. But when i try to use commands as simple as help("lm"), it doesnt work nor any of the menu "Packages" is not working. Although the regression using lm ( Y ~ X ) is working
2009 May 12
1
Can anyone suggest some r packages for Experimental Designs, specifically for choice and conjoint??? (or is intersted in helping me make 1)
Afternoon everyone, I''ve spent the last week or so looking at all the experimental design packages I can find in R. AlgDesign, design.conf and BHH2 being the best one I could find. Unfortunately none of these do a particularly good job for complex designs, in particular for conjoint or discrete choice. (or perhaps they do, and I can''t make them work correctly)
2010 Jun 03
3
Interaction versus combinations
I can get the interactions between factors like this: > idx=c(1,3,6,9) > jdx=idx > levels(interaction(idx,jdx,lex.order=TRUE)) [1] "1.1" "1.3" "1.6" "1.9" "3.1" "3.3" "3.6" "3.9" "6.1" "6.3" "6.6" "6.9" [13] "9.1" "9.3" "9.6"
2011 Oct 26
2
dotPlot with diagonal
Hi, I want draw a dotPlot. All works fine: (Seq <- matrix(c(1, 1, 6, 1, 2, 2, 5, 4, 3, 3, 4, 3, 4, 4, 3, 2, 5, 5, 2, 5, 6, 6, 1, 6), ncol = 6)) dotPlot(Seq[1,], Seq[2,], main = "Sequenz 1 und Sequenz 2", asp = 1) Is there a way to draw a small diagonal, begin at (0/0) to (6/6) (perhaps in red??) or must I use gimp? I have many dotPlots, so it is fine if R can do this. Thanks Joerg
2011 Feb 08
2
Frequency plot --- stacked symbols
Hi, We were wondering how we could make a stacked frequency diagram such as this one: http://msemac.redwoods.edu/~darnold/math15/liz.pdf We don't necessarily need the shaded "balls", other characters would be fine, such as stacks of x's. David
2012 Sep 13
1
fractional balanced design conjoint analysis
L.S. We would like to generate fractional design for a conjoint analysis. For example we would like to reduce 2x2x2x2x3 --> 12-16 profiles. We tried the R-package "conjoint" and we found an article which describes how to make fractional design for these kinds of studies with Algdesign: http://tolstoy.newcastle.edu.au/R/e10/help/att-8876/DCE_with_R.pdf However, the generated
2003 May 22
3
How to avoid function masking
Hi All, I've been working on updating the 'genetics' package. As a consequence of the upgrade, .First.lib() looks like: .First.lib <- function(libname, pkgname) { if (!require(combinat)) warning("Unable to load 'combinat' library. Function `diseq.ci' will fail.") require(gregmisc) genotype <-
2007 Aug 28
2
Experimental Design with R
Dear R-users, I want to know if there is a package that allows to define different experimental designs (factorial, orthogonal, taguchi) and to compare them. I don't found one in the R-web site, but it is possible I missed it! Thank you in advance Sincerely, Marc
2013 Sep 06
1
Importing function that is previously imported by other package
Dear developeRs, I encounter the following problem: in the current version of my package FrF2, certain calls to a functioni do not work when package combinat is loaded, because function combn from combinat masks the function from utils that my package uses. I tried to solve this issue by importing function combn into the namespace of FrF2; I don't need to export it, I just want to use it
2005 Apr 04
1
Handling very large integers with factorial and combinat (nCm)
Dear list, perhpas this question is more suitable for R-dev but since I am not really a developer I post it here first. Apparently the following lines do not create any problem in R: library(combinat) r <- 20; b <- 2; sum( sapply(0:r,function(x) nCm(r,x)^(2*b)) ) > 2^64 while in C I obtain an overflow of data even using unsigned long long and with long double I incurr in precision
2008 Sep 03
2
ANCOVA/glm missing/ignored interaction combinations
Hi I am using R version 2.7.2. on a windows XP OS and have a question concerning an analysis of covariance with count data I am trying to do, I will give details of a scaled down version of the analysis (as I have more covariates and need to take account of over-dispersion etc etc) but as I am sure it is only a simple problem but I just can't see how to fix it. I have a data set with count