Text Box [text.box()]

Dot Plot [tplot()]

  • This is an alternative to stripchart() and stripplot().
  • dotplot.html: dotplot help

An Example

set.seed(100)
age <- rnorm(80,rep(c(26,36),c(70,10)),4)
sex <- sample(c('Female','Male'),80,T)
group <- paste('Group ', sample(1:4,40,prob=c(2,5,4,1),replace=T), sep='')
d <- data.frame(age,sex,group)
tplot(age~group,data=d,show.n=T,type=c('db','db','db','d'),col=c(d$sex),dist=.2,jit=.05,  las=1,pch=19)
legend('topright',pch=19,col=1:2,legend=c('Female','Male'))

showColors.png

Miscellaneous R functions

Show colors

In R, there are 657 named colors. The following funciton, show.colors(), shows these colors and corresponding numbers.
Find the color you like in the plot. You can find the name of the color by running >colors()[number], eg:

> colors()[465]
[1] "mediumorchid3"

showColors.png

Topic attachments
I Attachment Action Size Date Who Comment
elsecsv Beatlesongs072108.csv manage 10.3 K 10 Oct 2008 - 17:18 TatsukiKoyama  
pdfpdf BeatlesongsPoster.pdf manage 66.8 K 10 Oct 2008 - 17:11 TatsukiKoyama  
pdfpdf BeatlesongsPoster2.pdf manage 66.9 K 10 Oct 2008 - 18:05 TatsukiKoyama  
pdfpdf Poster3.pdf manage 60.7 K 13 Nov 2008 - 09:17 TatsukiKoyama  
elser RcodeTplot.r manage 8.2 K 05 Feb 2009 - 13:11 TatsukiKoyama  
elser TatsukiRcodeMisc.r manage 9.2 K 16 Sep 2009 - 12:54 TatsukiKoyama  
elser TatsukiRcodeTextBox.r manage 10.6 K 29 Jun 2009 - 16:57 TatsukiKoyama  
elser TatsukiRcodeTplot.r manage 9.7 K 18 Aug 2009 - 10:12 TatsukiKoyama  
elser TatsukiRcodeTplot2.r manage 9.9 K 17 Aug 2009 - 12:36 TatsukiKoyama  
elser TextBoxExample.r manage 2.2 K 10 Oct 2008 - 16:33 TatsukiKoyama  
elser USEFUL.r manage 32.7 K 11 Nov 2008 - 09:20 TatsukiKoyama  
elser beatlesongs.r manage 13.5 K 17 Oct 2008 - 09:48 TatsukiKoyama  
htmlhtml tatsukiplot.html manage 7.4 K 10 Oct 2008 - 17:47 TatsukiKoyama  
htmlhtml textbox.html manage 7.1 K 10 Oct 2008 - 17:51 TatsukiKoyama  
Topic revision: r60 - 16 Sep 2009 - 12:54:18 - TatsukiKoyama
 
Register | Log In
Copyright © 2009 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding Foswiki? Send feedback