開始使用免費開始

基本折線圖

這裡我們會使用 economics 資料集來繪製一些折線圖。這個資料集包含來自美國聖路易聯邦儲備銀行的失業與人口統計時間序列。資料包含在 ggplot2 套件中。

首先,你可以觀察中位失業時間與失業率(失業人口占總人口的比例)如何隨時間變化。

本練習屬於課程

ggplot2 資料視覺化入門

檢視課程

動手互動練習

試著完成這個範例程式碼,體驗一下這個練習。

# Print the head of economics
___

# Using economics, plot unemploy vs. date
___ +
  # Make it a line plot
  ___
編輯並執行程式碼