1 rates <- read.csv("../tables/all.csv")
\r
2 title = "Indirect to Total Labor, as Percent \n 2010, 2011"
\r
3 y1 = rates$indirect.hours.outbound.2011/(rates$direct.hours.outbound.2011 + rates$indirect.hours.outbound.2011)
\r
4 y2 = rates$indirect.hours.outbound.2010/(rates$direct.hours.outbound.2010 + rates$indirect.hours.outbound.2010)
\r
8 png(file="indirect_out_vs_total_2010_2011.png",
\r
9 width=5, height=3.5, units="in", res=res)
\r
10 xlab.text="Week in Year"
\r
13 if (make.title == T ) top.margin = 3
\r
14 if (make.title != T ) title=""
\r
15 if (months.grid == T) bottom.margin = 6
\r
16 if (months.grid == T) xlab = ''
\r
17 margins=c(bottom.margin, 4, top.margin, 0.5)
\r
20 par('family'='serif')
\r
21 y_range = range(y1,y2, na.rm=T)
\r
22 plot(x, type='n', xlab=xlab, ylab=ylab, las=1, main=title,
\r
23 ylim=c(y_range), axes=F, xlim=c(range(x)))
\r
25 axis(2, col=ax_col, las=1, at=axTicks(2))
\r
27 rect(38, -10, 39, 300, col=rec_col, border=NA, xpd = F)
\r
28 abline( h=axTicks(2), lty=1, lwd=lwd_grid, col=ax_col)
\r
29 abline( h=100, lwd=1, col=base_line_col, lty=base_line_type)
\r
31 lines(x,y1, col=line_colors[2], type="l", lwd=lwd, lty=line_types[2])
\r
32 lines(x,y2, col=line_colors[1], type="l", lwd=lwd, lty=line_types[1])
\r
33 source("make_x_axis.R")
\r
35 legend("topleft", c("2010","2011"), cex=legend_font_size,
\r
36 col=line_colors, lty=line_types, bty='y', bg="white", box.lwd=box.lwd)
\r
39 result <- t.test(var.equal=T, y2,y1, alternative="g")
\r
40 y1 = rates$direct.hours.outbound.2011/1000
\r
41 y2 = rates$direct.hours.outbound.2010/1000
\r
42 title = "Direct Hours, 2010, 2011"
\r
43 #png(file="direct_out_hours_2010_2011.png",
\r
44 #width=5, height=3.5, units="in", res=res)
\r
45 #xlab.text="Week in Year"
\r
47 #ylab = "hours in thousands"
\r
48 #if (make.title == T ) top.margin = 3
\r
49 #if (make.title != T ) title=""
\r
50 #if (months.grid == T) bottom.margin = 6
\r
51 #if (months.grid == T) xlab = ''
\r
52 #margins=c(bottom.margin, 4, top.margin, 0.5)
\r
55 #par('family'='serif')
\r
56 #y_range = range(y1,y2, na.rm=T)
\r
57 #plot(x, type='n', xlab=xlab, ylab=ylab, las=1, main=title,
\r
58 # ylim=c(y_range), axes=F, xlim=c(range(x)))
\r
59 #axis(1, col=ax_col)
\r
60 #axis(2, col=ax_col, las=1, at=axTicks(2))
\r
62 #rect(38, -10, 39, 300, col=rec_col, border=NA, xpd = F)
\r
63 #abline( h=axTicks(2), lty=1, lwd=lwd_grid, col=ax_col)
\r
64 #abline( h=100, lwd=1, col=base_line_col, lty=base_line_type)
\r
66 #lines(x,y1, col=line_colors[2], type="l", lwd=lwd, lty=line_types[2])
\r
67 #lines(x,y2, col=line_colors[1], type="l", lwd=lwd, lty=line_types[1])
\r
68 #source("make_x_axis.R")
\r
70 #legend("topleft", c("2010","2011"), cex=legend_font_size,
\r
71 # col=line_colors, lty=line_types, bty='y', bg="white",
\r
75 title ="Direct Rate 2011, 2010"
\r
77 y1 = rates$units.outbound.2011/rates$direct.hours.outbound.2011
\r
78 y2 = rates$units.outbound.2010/rates$direct.hours.outbound.2010
\r
79 png(file="direct_vs_total_2010_2011.png",
\r
80 width=5, height=7, units="in", res=res)
\r
82 xlab.text="Week in Year"
\r
84 ylab = "units/man hour"
\r
85 if (make.title == T ) top.margin = 3
\r
86 if (make.title != T ) title=""
\r
87 if (months.grid == T) bottom.margin = 6
\r
88 if (months.grid == T) xlab = ''
\r
89 margins=c(bottom.margin, 4, top.margin, 0.5)
\r
92 par('family'='serif')
\r
93 y_range = range(y1,y2, na.rm=T)
\r
94 plot(x, type='n', xlab=xlab, ylab=ylab, las=1, main=title,
\r
95 ylim=c(y_range), axes=F, xlim=c(range(x)))
\r
97 axis(2, col=ax_col, las=1, at=axTicks(2))
\r
99 abline( h=axTicks(2), lty=1, lwd=lwd_grid, col=ax_col)
\r
100 abline( h=100, lwd=1, col=base_line_col, lty=base_line_type)
\r
102 lines(x,y1, col=line_colors[2], type="l", lwd=lwd, lty=line_types[2])
\r
103 lines(x,y2, col=line_colors[1], type="l", lwd=lwd, lty=line_types[1])
\r
104 source("make_x_axis.R")
\r
106 legend("bottomleft", c("2010","2011"), cex=legend_font_size,
\r
107 col=line_colors, lty=line_types, bty='y', bg="white",
\r
110 # t.test(y2, y1, var.equal=T, alter="g", mu=13, conf.int = 97.5)
\r
113 title ="Outbound Rate, Total"
\r
114 y1 = rates$rate.outbound.2010
\r
115 y2 = rates$rate.outbound.2011
\r
116 y_range <- range(y1, y2, na.rm=T)
\r
117 xlab.text="week in year"
\r
119 ylab = "units/man hour"
\r
120 if (make.title == T ) top.margin = 3
\r
121 if (make.title != T ) title=""
\r
122 if (months.grid == T) bottom.margin = 6
\r
123 if (months.grid == T) xlab = ''
\r
124 margins=c(bottom.margin, 4, top.margin, 0.5)
\r
126 par('family'='serif')
\r
127 plot(x, type='n', xlab=xlab, ylab=ylab, las=1, main=title, ylim=c(y_range), axes=F)
\r
128 axis(1, col=ax_col)
\r
129 axis(2, col=ax_col, las=1, at=axTicks(2))
\r
131 abline( h=axTicks(2), lty=1, lwd=lwd_grid, col=ax_col)
\r
132 lines(x,y1, col=line_colors[1], type="l", lwd=lwd, lty=line_types[1])
\r
133 lines(x,y2, type="l", col=line_colors[2], lwd=lwd, lty=line_types[2])
\r
134 legend("bottomleft", c("2010","2011"), cex=legend_font_size,
\r
135 col=line_colors, lty=line_types, bty='y', bg="white", box.lwd=box.lwd)
\r
136 source("make_x_axis.R")
\r
138 # 8592292121 Billy Redmond's number
\r
139 # t.test(y1,y2, var.equal=T, alter="g", mu=6, conf.int = 97.5)
\r
144 #png(file="indirect_outbound_2010_2011.png",
\r
145 #width=5, height=7, units="in", res=res)
\r
146 #title ="percent change indirect outbound, 2010, 2011"
\r
148 #y1 <- rates$indirect.hours.inbound.2010/rates$hours.inbound.2010
\r
149 #y2 <- rates$indirect.hours.inbound.2011/rates$hours.inbound.2011
\r
150 #rates$indirect.hours.2010
\r
155 #y_range <- range(y1,y2, na.rm=T)
\r
156 #xlab.text="week in year"
\r
158 #ylab = "percent change"
\r
159 #if (make.title == T ) top.margin = 3
\r
160 #if (make.title != T ) title=""
\r
161 #if (months.grid == T) bottom.margin = 6
\r
162 #if (months.grid == T) xlab = ''
\r
163 #margins=c(bottom.margin, 4, top.margin, 0.5)
\r
165 #par('family'='serif')
\r
166 #plot(x, type='n', xlab=xlab, ylab=ylab, las=1, main=title, ylim=c(y_range), axes=F)
\r
167 #axis(1, col=ax_col)
\r
168 #axis(2, col=ax_col, las=1, at=axTicks(2))
\r
170 #abline( h=axTicks(2), lty=1, lwd=lwd_grid, col=ax_col)
\r
171 #abline( h=100, lty=2, lwd=2, col="red")
\r
172 #lines(x,y1, col=line_colors[1], type="l", lwd=lwd, lty=line_types[1])
\r
173 #lines(x,y2, col=line_colors[2], type="l", lwd=lwd, lty=line_types[2])
\r
174 #legend("topleft", c("2010","2011"), cex=legend_font_size,
\r
175 # col=line_colors, lty=line_types, bty='y', bg="white", box.lwd=box.lwd)
\r
176 #source("make_x_axis.R")
\r
178 ## 8592292121 Billy Redmond's number
\r
179 ## t.test(y1,y2, var.equal=T, alter="g", mu=6, conf.int = 97.5)
\r