Skip to content

Commit 01e2453

Browse files
committed
weibull_distribution : グラフを2つにわけた #5
1 parent 36d3df3 commit 01e2453

File tree

3 files changed

+6
-3
lines changed

3 files changed

+6
-3
lines changed

reference/random/weibull_distribution/random_stats.R

+6-3
Original file line numberDiff line numberDiff line change
@@ -7,13 +7,16 @@ png("weibull_distribution.png")
77
x <- read.table("weibull_distribution.tsv")
88

99
# 1列ずつ抜き出す
10-
values = x$V1
10+
value1 = x$V1
1111
value2 = x$V2
1212

1313
# プロットとして出力
1414
#plot(density(value1), xlim=c(-1,10), ylim=c(0.0,0.8), lty="longdash", col=rgb(0,1,0))
1515
#par(new=T)
1616
#plot(density(value2), xlim=c(-1,10), ylim=c(0.0,0.8), col=rgb(0,0,1))
1717

18-
hist(values, col=rgb(0,1,0,0.2), main="")
19-
hist(value2, col=rgb(0,0,1,0.2), add=T)
18+
# グラフを縦に2つ
19+
par(mfrow=c(2, 1))
20+
21+
hist(value1, col=rgb(0,1,0,0.2))
22+
hist(value2, col=rgb(0,0,1,0.2))
Loading
Binary file not shown.

0 commit comments

Comments
 (0)