similar to: adjusting textsize and spacing in mosaic (vcd package)

Displaying 20 results from an estimated 1100 matches similar to: "adjusting textsize and spacing in mosaic (vcd package)"

2007 Sep 19
4
fontsize in mosaic plot lables
Hi List, I am trying unsucessfully to modify the fontsize of lables in mosaic: require(vcd) mosaic(Titanic, pop=FALSE, labeling_args=list(rot_labels=c(bottom=90,top=90), set_varnames = c(Sex = "Gender"), gp_text=gpar(fontsize=20))) #can't get it to resize text tab <- ifelse(Titanic < 6, NA, Titanic) # it works for labeling_cells labeling_cells(text = tab,
2006 Dec 06
2
vcd package, assoc()
Hello, I am trying to use the extended assocplot() function: assoc(), from vcd package. Trouble is that it cannot even run its own examples on my installation. I get this output: $> example(assoc) assoc> data("HairEyeColor") assoc> (x <- margin.table(HairEyeColor, c(1, 2))) Eye Hair Brown Blue Hazel Green Black 68 20 15 5 Brown 119 84 54
2011 Mar 30
4
fonts in mosaic
I need to change the font(s) used in mosaic from package vcd. The help file and the vignette do not give very explicit examples for doing that. The easiest solution would be changing the font for everything on the graph: var labels, var names, title, subtitle, and cell labels. What is the easiest way of accomplishing this?
2006 Jan 27
1
monochrome mosaic plot in vcd package
helpeRs, I have a nice looking mosaic plot in an article to be published soon. Sadly, the published version will be in black and white and so ruin the advantage of the default shading scheme of tiles. What would readers suggest as an alternative shading scheme? If I have a black-and-white shading scheme graduated according to suitable cutoffs I won't be able to tell positive from
2001 Nov 30
1
mosaic.by(): vectorizing args passed by apply()?
I've just started learning R, so I'm still on the steep part of the learning curve, but my enthusiasm was heightened by learning that there's a very nice implementation of mosaicplot(). As a learning project, I've already done a basic implementation of a pairs.table() function which does a mosaic scatterplot matrix, and now I'm trying to do conditional mosaic plots (discrete
2012 May 02
0
adding a caption to a mosaic plot?
Dear all: Is there a way to add text to the margins or outer margins of a mosaic plot using the vcd package? I understand the margins argument to mosaic, but I don't know how to add text to that. I'd like to add a caption to a plot. If possible, I'd like to know how to set the font and size for that function as well. My plot looks roughly as below. Thank you for your time! Simon J.
2002 Jan 30
1
mosaicplot(formula, data)--- bugged?
I have been tinkering with mosaicplot() and friends as a way of learning R. As part of this, I've written a pair.table() method for mosaic matrices, and would like to extend mosaicplot to work with loglin and logln (MASS) objects. I'm using R 1.4.0 on Win 98. I've been trying to figure out the formula interface, and think there's a bug, but not sure how to find it, yet alone fix
2013 Aug 18
1
How does R_UnboundValue and removing variables work?
Reading "R Internals" made me believe that R_UnboundValue was a placeholder that would be skipped over in variable lookup. viz. the section of R Internals "Hash tables" says "items are not actually deleted but have their value set to R_UnboundValue.", which seems to align with what I read in envir.c. So, I reasoned, if I have a function that returns R_UnboundValue,
2002 Feb 08
2
bugs or imperfect implementation?
I am using R to teach, and here are a couple of things that I thought would work didn't work. 1. I noticed the utility data(***,package=***) recently and like it very much, but unless I type in the whole word "package" I'll get an error in 1.4.0. For example, data(cats,package=MASS) works fine but data(cats,pac=MASS) doesn't. 2. drop1 doesn't seem to be as smart as
2011 Oct 31
1
Help combining cell labelling and multiple mosaic plots
Dear colleagues I'm using data that looks like .test and .test1 below to draw two mosaic plots with cell labelling (the row percentages from the tables). When I take out the pop=FALSE commands in the mosaic commands and comment out the two lines labelling the cells, then the plots are laid out exactly as I'd like: side-by-side. But I do require the cell labelling and the pop=FALSE
2013 Feb 08
1
color query in mosaic in package vcd
require(vcd) mosaic(matrix(1:6, 2, 3), gp=gpar(fill=c("red","gray","blue")), main="three colors in each row") mosaic(matrix(1:3, 1, 3), gp=gpar(fill=c("red","gray","blue")), main="only one color in each row") I anticipated three colors in the second plot. My guess is that there is a matrix subscript without
2008 May 02
2
mosaic plot of "vcd" package does not stretch with 2-dimension?
Hi, I like mosaic function of "vcd" package. I have played around it. I have found out that mosaic plot data table is 2-dimension does not stretch when you enlarge a mosaic plot. It is okay when data table is 3 or more dimension. The first one is of 3-dimension table case, and the second one is 2-dimension. With the first plot, you can drag window to enlarge a plot. With the
2012 Apr 06
2
Changing grid defaults
I'm trying to use the vcd package to produce mosaic plots for my class notes, written in Sweave and using the LaTeX's beamer document class. For projecting the notes in class, I use a dark background with light foreground colors. It's easy enough to change the defaults for R's standard graphics to match my color scheme (using the fg, col.axis, col.lab, col.main, and col.sub
2008 Nov 16
3
chisq.test with simulate.p.value=TRUE (PR#13292)
Full_Name: Reginaldo Constantino Version: 2.8.0 OS: Ubuntu Hardy (32 bit, kernel 2.6.24) Submission from: (NULL) (189.61.88.2) For many tables, chisq.test with simulate.p.value=TRUE gives a p value that is obviously incorrect and inversely proportional to the number of replicates: > data(HairEyeColor) > x <- margin.table(HairEyeColor, c(1, 2)) >
2005 Nov 12
1
how to make automatically each level from data.frame to vector
Dear R-helpers, Suppose I have dataset like this below: data(HairEyeColor) dfHEC <- as.data.frame(as.table(HairEyeColor)) my.dfHEC <- data.frame(Hair=rep(dfHEC$Hair,dfHEC$Freq), Eye=rep(dfHEC$Eye,dfHEC$Freq), Sex=rep(dfHEC$Sex,dfHEC$Freq)) my.dfHEC my.dfHEC$Hair my.dfHEC$Eye my.dfHEC$Sex and I know all levels for Hair, Eye and Sex. In my case, I
2009 Dec 15
2
Diagonal Labels on "Beside" Bars in Barplot
My question is based on an example provided in the following: Referencing: Statistics with R Vincent Zoonekynd <zoonek at math.jussieu.fr> 6th January 2007 URL: http://zoonek2.free.fr/UNIX/48_R/all.html data(HairEyeColor) a <- as.table( apply(HairEyeColor, c(1,2), sum) ) # Provided Example barplot(a, beside = TRUE, legend.text = attr(a, "dimnames")$Hair) # I
2010 Sep 19
1
odds ratios for n-way tables: seeking an *apply-able method
I'm looking for a way to generalize the calculation of (log) odds ratios for 2 x 2 x {strata} frequency tables in vcd::oddsratio() to R x C x {strata} tables. For an R x C table, F, odds ratios can be defined in several ways; one simple way, particularly for tables with ordered factors, is to calculate the set of continuation odds ratios, based on the (R-1)x(C-1) set of 2x2 tables with
2010 May 12
2
Finding different hues for a mosaic plot compatible with grayscale printing
I'm working with the following code below to generate a how do I set the h,c, and l values such that the significant, positive residuals appear different on a grayscale printer from significant grayscale residuals. The challenge as I see it is that one can only distinguish the positive and negative residuals with the hue/. Varying the chroma and the luminance only affect the
2002 Sep 13
1
[R] proposal: mosaicplot with sub and las
Two proposals for mosaicplot(): - The argument "sub" should not be ignored. Example: mosaicplot( HairEyeColor, sub = 'test of sub' ) - To be able to discern also longer axis labels the argument "las" or par(las=2) should not be ignored. Example: mosaicplot( HairEyeColor, las=2 ) Thanks Wolfram
2012 Dec 18
2
Changing Variable Names In VCD
Hello: What is the most efficient way to change the plotted variable names in mosaic plots in the vcd package? Should one do a separate contingency table first, change the dimension names there and then pass that to mosaic? Or is there a way to do it simply within mosaic. I was thinking something like: mosaic(~var1+var2, labelling_args=list(varnames=c('newvar1', 'newvar2')) Simon