我想讀取5 csv文件。我有以下功能分別繪製圖表,我想爲每個圖表添加一個圖例。然而,我得到了這個警告,即使我有一個標籤添加到我的函數中,圖例並沒有被添加到圖中。 UserWarning: No labelled objects found. Use label='...' kwarg on individual plots. warnings.warn("No labelled objects f
我嘗試使用ggplot2分別使用fill和alpha對barplot中的兩個離散變量進行可視化。這樣做的標準方法如下: #creating data and building the basic bar plot
library(ggplot2)
myleg<-read.csv(text="lett,num
a,1
a,2
b,1
b,2
h,1
h,2
h,3
h,4")