I have been trying to visualise my data (saved as a data.table) as a boxplot however I can't seem to make it work and keep getting the error:
Error in x[floor(d)] + x[ceiling(d)] : non-numeric argument to binary operator
Which I assume is due to the fact that I'm using a data.table rather than a data.frame?
The code which I'm using:
metadata = read.table("Metadata.txt", stringsAsFactors = FALSE,
header = TRUE, sep = "\t")
conds = as.factor(metadata$Treatment)
cond_colours = brewer.pal(length(unique(conds)), "Set1")[as.factor(conds)]
names(cond_colours) = conds
boxplot1 <- boxplot(vis_data, col=cond_colours, las=2, cex.axis=.6)
Does anybody know of any work around that can help me visualise my data? Thanks