×
[PR]上記の広告は3ヶ月以上新規記事投稿のないブログに表示されています。新しい記事を書く事で広告が消えます。
前に描いた3要因グラフ (記事) を微調整した。-> 微調整後
c1m <- c(1,4)
c1n <- c(3,2) ## Condition 1
c2m <- c(5,3)
c2n <- c(1,4) ## Conditon 2
c1dat <- cbind(c1m, c1n)
rownames(c1dat) <- c("a", "b")
c2dat <- cbind(c2m, c2n)
rownames(c2dat) <- c("a", "b")
xlm <- c(0.8, 2.2)
ylm <- c(0, 6)
# 作図の領域を指定
par(mfrow = c(1, 2), mar = c(4,0,4,0), oma = c(4,6,2,4), bty = "l", lwd = 2)
## Condition 1のグラフ描画
matplot(c1dat, type = "b", pch = 1:2, col = 1, xlim = xlm, ylim = ylm, xaxt = "n", xlab = "Condition 1", cex = 1.5, cex.axis = 1.5, cex.lab = 1.5, lwd = 2, yaxp = c(0, 6, 12))
axis(1, at = 1:2, labels = c("a", "b"), cex.axis = 1.5)
## Condition 2のグラフ描画
matplot(c2dat, type = "b", pch = 1:2, col = 1, xlim = xlm, ylim = ylm, axes = F, xlab = "Condition 2", cex = 1.5, cex.axis = 1.5, cex.lab = 1.5, lwd = 2)
axis(1, at = xlm, tck = 0, labels = F, lwd = 2, cex.axis = 1.5)
axis(1, at = 1:2, c("a", "b"), cex.axis = 1.5, lwd = 2)
## 凡例描画
legend("topright", legend = c("m", "n"), lty = 1:2, pch = 1:2, box.lty = 0,cex = 1.2, pt.cex =1.2)
## 軸タイトル
mtext("OUT CONDITION", outer = T, side = 1, line =1, cex = 1.5)
mtext("Dep.Var. (Time)", outer = T, side = 2, line = 3, cex = 1.5)
c1m <- c(1,4)
c1n <- c(3,2) ## Condition 1
c2m <- c(5,3)
c2n <- c(1,4) ## Conditon 2
c1dat <- cbind(c1m, c1n)
rownames(c1dat) <- c("a", "b")
c2dat <- cbind(c2m, c2n)
rownames(c2dat) <- c("a", "b")
xlm <- c(0.8, 2.2)
ylm <- c(0, 6)
# 作図の領域を指定
par(mfrow = c(1, 2), mar = c(4,0,4,0), oma = c(4,6,2,4), bty = "l", lwd = 2)
## Condition 1のグラフ描画
matplot(c1dat, type = "b", pch = 1:2, col = 1, xlim = xlm, ylim = ylm, xaxt = "n", xlab = "Condition 1", cex = 1.5, cex.axis = 1.5, cex.lab = 1.5, lwd = 2, yaxp = c(0, 6, 12))
axis(1, at = 1:2, labels = c("a", "b"), cex.axis = 1.5)
## Condition 2のグラフ描画
matplot(c2dat, type = "b", pch = 1:2, col = 1, xlim = xlm, ylim = ylm, axes = F, xlab = "Condition 2", cex = 1.5, cex.axis = 1.5, cex.lab = 1.5, lwd = 2)
axis(1, at = xlm, tck = 0, labels = F, lwd = 2, cex.axis = 1.5)
axis(1, at = 1:2, c("a", "b"), cex.axis = 1.5, lwd = 2)
## 凡例描画
legend("topright", legend = c("m", "n"), lty = 1:2, pch = 1:2, box.lty = 0,cex = 1.2, pt.cex =1.2)
## 軸タイトル
mtext("OUT CONDITION", outer = T, side = 1, line =1, cex = 1.5)
mtext("Dep.Var. (Time)", outer = T, side = 2, line = 3, cex = 1.5)
PR
Comment
Trackback
Trackback URL
Comment form