我想使用 R 和任何使它看起来不错的包输出类似于此页面(右侧)上显示的图表:
http://processtrends.com/pg_charts_monthly_cycle_chart.htm
有人敢挑战吗? :)
谢谢!
最佳答案
stats
R base 中的包已经有一个功能可以做到这一点。这是我的单行和它产生的输出
monthplot(redata, labels = month.abb, ylab = 'Listings')
在此基础上,使用月图绘制每周周期图的示例在这里(提供完整的 R 代码和源数据):http://figshare.com/figures/index.php/OpenURL_Router_Data:_Total_Requests_by_Weekday
monthplot(ts(sdf$values, frequency = 7, start=c(12,5)), labels = dow, ylab = "No. requests / day", xlab = "Weekday")
这给出了这个每周周期图:
Example of monthplot to create a graph showing a weekly cycle http://figshare.com/figures/images/a/a7/Total_requests_by_weekday_01_Apr_to_31_Jul_2011.jpeg
关于r - 如何在 R 中复制月度周期图,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/5826703/