1

Rで機能するようにポイントを追加しようとしてfilled.countourいますが、成功していません。この古い投稿をフォローしました。私のプロットには、緑色の点が表示されます。PointColorsカラー バンド (この場合) で指定されたように色が変化する点のシーケンスを探しています。理由がわかりません...

これが私のコードです:

dat1 <-structure(c(5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 8.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 6.9, 5.5, 8.5, 5.5, 6.9, 6.9, 5.5, 5.5, 5.6, 6.9, 5.5, 5.5, 5.5, 8.1, 5.5, 5.5, 5.5, 5.5, 5.5, 7.5, 5.5, 5.5, 5.5, 7.5, 5.7, 4.6, 5.7, 5.5, 5.5, 5.7, 6.5, 3.2, 5.5, 5.5, 5.5, 5.5, 5.5, 5.5, 8.2, 5.5, 8.2, 5.5, 5.5, 5.6, 5.5, 5.5, 5.1, 5.5, 5.5, 5.5, 5.5, 6.3, 5.5, 3.6, 5.5, 5.5, 5.5, 5.5, 5.5, 6.2, 5.4, 6.6, 5.5, 5.8, 6.2, 5.5, 5.5, 5.5, 5.6, 5.4, 5.5, 5.8, 5.5, 5.5, 5.5, 6.1, 5.5, 6.5, 2.3, 5.5, 6.1, 5.5, 5.5, 7, 5.5, 5.8, 5.5, 5.5, 7.6, 4.1, 5.5, 6.8, 4.6, 1.5, 5.5, 5.5, 5.7, 5.7, 5.5, 3.4, 5.7, 5.5, 5.5, 5.5, 5.5, 5.7, 7.4, 5.7, 5.5, 5.7, 5.5, 5.5, 5, 1, 5.5, 4.2, 2.2, 5.5, 4.7, 3.2, 5.5, 4.5, 4.5, 4, 2.4, 5.5, 2.5, 4.1, 5.7, 5.5, 1.9, 3.6, 4.6, 3, 4.6, 5.5, 4, 3.7, 5.5, 4.6, 5.5, 5.5, 4.6, 4.7, 3.6, 5.5, 5.5, 4.6, 3.7, 4.6, 4.6, 6, 4, 5.5, 4.9, 1.6, 5.5, 6.6, 5.2, 6.4, 6.4, 4.9, 6.2, 6.2, 6.5, 6.4, 5.3, 5.5, 3.6, 5.7, 7.4, 5.9, 2.4, 5.3, 8.5, 5.3, 5.5, 7.4, 6, 5.5, 5.5, 3.3, 4.6, 8.5, 6.1, 5.5, 5.5, 5.5, 5.5, 6.9, 5.5, 6.5, 7, 6.4, 5.3, 8.2, 7.3, 2.4, 7.1, 6.3, 7.7, 3.9, 8.2, 6.3, 6.7, 8, 7.2, 5.6, 4.7, 7.7, 6.6, 5.2, 5.5, 5.2, 5.3, 5.2, 5.4, 5.5, 2.8, 7, 5.7, 6.8, 4.6, 6.2, 5.5, 5.8, 7.3, 5.1, 4.8, 3.5, 5.5, 5.8, 6.4, 6.7, 5.5, 5.5, 5.5, 5.5, 4.8, 6.7, 4.7, 7.2, 5.5, 3.5, 5.5, 4.9, 5.5, 5.5, 6.7, 3.7, 5.5, 5.5), .Dim = c(20L, 16L), .Dimnames = list(NULL, c("estimated", "estimated", "estimated", "estimated", "estimated", "estimated", "estimated", "estimated", "estimated", "estimated", "estimated", "estimated", "estimated", "estimated", "estimated", "estimated")))

Contourcolors <- colorRampPalette(c('yellow',"red"))(20)
PointColors <- c(rep('green',5),rep('blue',5))
filled.contour(dat1,col=Contourcolors,plot.axes={points((1:20),rep(.5,20),col=PointColors,cex=5,pch=19)})

これがプロットです。 ここに画像の説明を入力

4

1 に答える 1