TL;DR: I'm getting the above (and below) error. How do I fix it?
Since I'm relatively new to R, this has me stumped. I'm trying to create an xyplot
where both the axes are log-transformed. I've gotten this far:
library(lattice)
xyplot(`APC-H7-A`~`PE-Cy5-A`,lymphocytes, smooth=FALSE,
xlim=c(-100,10000), ylim=c(-100,10000),
scales=list(x=list(log=10),y=list(log=10)))
And I keep getting an error:
Error in Math.factor(x, xbase) : ‘log’ not meaningful for factors
I'm guessing that the error means something in my code isn't recognised as a number? but I don't really know where to start looking.
Lymphocytes is an object of flowFrame
class, within the flowCore
package:
Description. This class represents the data contained in a FCS file or similar data structure. There are three parts of the data:*
- A numeric matrix of the raw measurement values with rows=events and columns=parameters
- Annotation for the parameters (e.g. the measurement channels, stains, dynamic range)
- Additional annotation provided through keywords in the FCS file*