search for: sample_x

Displaying 1 result from an estimated 1 matches for "sample_x".

Did you mean: sample_1
2012 Apr 21
2
using "factor" to eliminate unused levels without dropping other variables
...that one or some of you can help. Here is the code I am trying to use: #importing data data.file <-read.csv("/file/location", header=TRUE, sep = ",") #selecting a subset of data based on variable "Sample" data.subset1 <- subset(data.file, subset=(Sample !='sample_x' & Sample !='sample_y')). **This leaves me a data file that has 8 levels of the variable "Sample" and 2 empty levels that correspond to sample_x and sample_y. I need to get rid of these two levels for plotting purposes, so I tried using the code below... data.subset2 &lt...