• R/O
  • SSH

Tags
No Tags

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

File Info

Rev. dba7d6381ff5e8fd92dc1380bec84212cb6e1b3a
크기 1,499 bytes
Time 2012-06-23 21:17:24
Author lorenzo
Log Message

I fixed a calculation and updated the picture.

Content

rm(list=ls())

library(tikzDevice)
library(ggplot2)


df <- 1.3

naumann <- sqrt((df+2.)/df)

Rg <- read.table("R_g_all.dat", header=FALSE)

Rgeo<- read.table("R_geo_all.dat", header=FALSE)

Rgeo <- (Rgeo+2.)/2.

ratio <- Rgeo/Rg

N <- read.table("N_clust_all.dat", header=FALSE)

mydata <- cbind(ratio, N)
names(mydata) <- c("ratio", "N")


b <- ggplot(mydata, aes(x=N, y=ratio)) +
           opts( panel.background=theme_rect(fill='white',
                   size=1.5))+
  opts(panel.grid.minor = theme_blank())+
opts(panel.grid.major = theme_blank())+
      opts(axis.ticks = theme_segment(colour = "black", size=1),
           axis.ticks.length = unit(0.15, "cm"))+

geom_point(size=2)+
## facet_grid(distance~ aggregate_number)+
  xlab("$N$")+
  ylab("$R_{geo}/R_g$")+
    scale_y_continuous(limits=c(1.3,1.9), breaks=seq(1.3,1.9, by=.1))+
  scale_x_continuous(limits=c(0,3200), breaks=seq(0,6000,by=1000))+

geom_hline(yintercept = naumann, col="blue", size=1)+
  
  opts(axis.title.x = theme_text(size = 20))+
  opts(axis.title.y = theme_text(size = 20, angle=90))+
  ## opts(axis.text.x = theme_text(size=15, colour="gray",vjust=1))+
  ## opts(axis.text.y = theme_text(size=15, colour="gray", hjust=1))
  opts(axis.text.x = theme_text(size=15, colour="black",vjust=1))+
  opts(axis.text.y = theme_text(size=15, colour="black", hjust=1))


fn <-'ratio_Rgeo_Rg_vs_N.tex' 

tikz(fn, standAlone = TRUE, width=5,height=5)


print(b)
dev.off()

tools::texi2dvi(fn,pdf=T)


print("So far so good")