「ぎょーむ日誌」目次に戻る | KuboWeb top に戻る | twilog | atom

ぎょーむ日誌 2000-07-21

苦情・お叱りは, たいへんお手数かけて恐縮ですが, 久保 (kubo@ees.hokudai.ac.jp) までお知らせください.

2000 年 07 月 21 日 (金)

Bar plot with R
xy <- scan( "bar.txt", list( x = 1, y0 = 1, y1 = 1 ) )
par( fig = c( 0.25, 0.75, 0.0, 1.0 ) )
plot(
	xy$x, xy$y0,
	ylim = range( xy$y0 ),
	type = "h", lty = 1,
	col = "red", lwd = 20,
	xlab = "x", ylab = "y",
	asp = 1
)
par( new = TRUE )
plot(
	xy$x, xy$y1,
	xlim = range( 0, 0, xy$x ),
	ylim = range( xy$y0 ),
	type = "h", lty = 1,
	col = "blue", lwd = 20,
	axes = FALSE,
	xlab = "", ylab = "",
	asp = 1
)
title( main="Sample Barplot", font.main=3 )
	

KuboLog | KuboWeb