You can also use the following
data<- structure(list(C.M = structure(c(3L, 3L, 3L, 2L, 2L, 4L, 4L,
4L, 1L, 1L, 1L), .Label = c("Apr", "Feb", "Jan", "Mar"), class = "factor"),
P.M = structure(c(3L, 2L, 5L, 2L, 5L, 5L, 1L, 6L, 1L, 6L,
4L), .Label = c("Apr", "Feb", "Jan", "Jun", "Mar", "May"), class = "factor"),
Value = structure(c(8L, 4L, 5L, 8L, 2L, 3L, 6L, 5L, 7L, 1L,
2L), .Label = c("1", "3", "4*", "5", "6", "7", "7*", "8*"
), class = "factor")), .Names = c("C.M", "P.M", "Value"), class = "data.frame", row.names = c(NA,
-11L))
df <- as.data.frame(reshape(data,idvar="C.M",timevar="P.M",direction="wide"))
print (df)