I have a question about the DEP r package. I didn't find the answer by looking at the documentation or the vignette (though I'm not an experienced r user, so I apologise if I missed it or didn't understand).
I would like to use a continuous variable in the condition column of my SummarizedExperiment object, rather than a categorical one (as in the example of the vignette).
The motivation is as follows: I have a number of different cell lines that I treat with different doses of a damaging agent. Using time-lapse microscopy I then track the motion of the cells of each type and at each dose level. I wish to see if cellular motility exhibits a dose dependence within cell lines and whether this putative positive/negative/no association between dose and speed (say) can be explained by comparing protein (and gene) expression. The level of correlation between speed and dose is a continuous variable between -1 and 1. I wish to use this continuous variable as the basis for my comparison (as the condition in my SummarizedExperiment object).
I could in principle discretise my continuous condition data into groups, but if I do that in the natural way for this example (positive association/negative association/uncorrelated) then one of the subgroups only has one member cell line (and no replicates of protein expression data), which I've been advised is a bad idea and information about the relative strengths of association is being lost.
Is it possible to run the analysis regressing against a continuous variable rather than categorical groups for the condition? This can, for instance, be done with the DEseq2 package - see my example code snippet below:
cts <- data
condition <- c(0.01,0.21,-0.26,-0.12,0.11,-0.19,0.02,0.06,-0.39,-0.33)
lines <- c("A498","A549","H460","HCT116","LOXIMVI",
"MALME3M","MCF7","SKMEL5","U2OS","UACC257",
"UACC62","UO31")
coldata <- cbind.data.frame(lines,condition)
dds <- DESeqDataSetFromMatrix(countData = cts, colData = coldata, design= ~condition)
dds <- DESeq(dds)
resultsNames(dds)
res <- results(dds, name="condition")
I would appreciate any help and apologise in advance if any of this made no sense or I completely misunderstood something.