Questions tagged «time-series»

时间序列是随时间(连续时间或离散时间段)观察到的数据。



2
如何在R中垂直堆叠具有相同x比例但不同y比例的两个图?
问候, 目前,我正在R中执行以下操作: require(zoo) data <- read.csv(file="summary.csv",sep=",",head=TRUE) cum = zoo(data$dcomp, as.Date(data$date)) data = zoo(data$compressed, as.Date(data$date)) data <- aggregate(data, identity, tail, 1) cum <- aggregate(cum, identity, sum, 1) days = seq(start(data), end(data), "day") data2 = na.locf(merge(data, zoo(,days))) plot(data2,xlab='',ylab='compressed bytes',col=rgb(0.18,0.34,0.55)) lines(cum,type="h",col=rgb(0,0.5,0)) summary.csv的片段: date,revision,file,lines,nclass,nattr,nrel,bytes,compressed,diff,dcomp 2007-07-25,16,model.xml,96,11,22,5,4035,991,0,0 2007-07-27,17,model.xml,115,16,26,6,4740,1056,53,777 2007-08-09,18,model.xml,106,16,26,7,4966,1136,47,761 2007-08-10,19,model.xml,106,16,26,7,4968,1150,4,202 2007-09-06,81,model.xml,111,16,26,7,5110,1167,13,258 ... 最后两行绘制了我需要的信息,其结果类似于以下内容: 蓝线是我感兴趣的工件的熵(以字节为单位)。绿线代表变化的熵。 现在,在此图中,它的效果很好,因为比例没有太大差异。但是我还有其他图表,其中的绿线变得很小,一个人看不到。 我正在寻找的解决方案涉及两件事: …
By using our site, you acknowledge that you have read and understand our Cookie Policy and Privacy Policy.
Licensed under cc by-sa 3.0 with attribution required.