Make Collectd Graph Panel show Apache records on FreeBSD 10.1
...
...
...
...
Another reminder of my classics. Sometimes, when you reduce data in a data frame some levels of categories are no longer contained in the observations after filtering but the factors still contain them in their levels. To clean these up use the following command: cleanfactor <- as.factor(as.character(oldfactor)) That’s it again. Cheers, iss
...
This is a classic in R and I tend to forget it every once in a while. So I write it down as a note for my future me. This line creates a gray scale with len steps: grey(1:len/len) This line creates a color scale going through hue, saturation, and value (luminance): hsv(1:len/len) This line creates a color scale using the hue, chroma, luminance space: hcl(1:360/len) That’s it again. Cheers, iss
This one is extremely useful if you want to create a quick histogram or stem plot in R. # makes line ends round (0) / butt (1) / square (2) par(las=2) That’s it iss
...
Yesterday I had to remind myself on how to remove the row names in a data.frame. Row names are usually added by filtering steps such as subset, etc. Assume we want to remove the row names of the data.frame called data, we can type: rownames(data) <- c() That’s it iss
...