\documentclass[fleqn,serif,hyperref={bookmarks=true}]{beamer}
\usepackage{bm,xcolor,color,listings,newcent,
graphicx,fancybox,pifont,latexsym} %txfonts,fouriernc
Archive for May, 2008
beamer setup
Posted by changjx on May 31, 2008
Posted in Latex | Tagged: beamer, Latex | Leave a Comment »
svg in R
Posted by changjx on May 1, 2008
library(“RSVGTipsDevice”)
library(“SemiPar”)
data(swiss)
setwd(‘c:/data/’)
devSVGTips(“swiss.svg”, height=7, width=10, toolTipMode=1,
title=”Swiss catholic and agriculture plot”)
par(font.lab=8,font.main=9,cex=1.5)
plot(swiss$Agriculture~swiss$Catholic,ylim=c(0,130),
type=”n”, xlab=”catholic”,ylab=”Agri”, main=”catholic and agriculture”)
grid()
cnames<-rownames(swiss)
swiss.1<-cbind(cnames,swiss)
for (i in seq(len=nrow(swiss.1))) {
setSVGShapeToolTip(title=swiss.1[i,"cnames"],
desc=paste(” agri=”, swiss.1[i,"Agriculture"],” ,catholic”, swiss.1[i,"Catholic"]))
points(swiss.1[i,"Agriculture"], swiss.1[i,"Catholic"], pch=12,
cex=2, col=ifelse(swiss.1[i,"Catholic"]>50,”blue”,”red”))
}
dev.off()
Posted in R | Tagged: R | Leave a Comment »