if
I use this script I face Error like
gene_list=read.table("exm9.csv",header = T,sep=',')
str(P.value)
head(gene_list$gene)
head(gene_list$P.value)
gene_list=(data.frame(P.value))
with(gene_list, plot(log2Foldchange, -log10(P.value), pch=20, main="Volcano plot"
Error in plot(log2FOldchange, -log10(P.value), pch = 20, main = "Volcano plot", : object 'log2FOldchange' not found |
|
|
Please, have a look on other codes, and forums before posting. Also these errors are not related to any Bioconductor package rather to R. Did you create an log2FOldchange? Also check if the gene_list$P.Value is character or numeric.
also
I used this code and got these errors I have no idea
gene_list$threshold = as.factor(abs(gene_list$Foldchange) > 2 & gene_list$P.Value < 0.05)
g = ggplot(data=gene_list, aes(x=Foldchange, y=-log10(P.value), colour=my_palette)) +
geom_point(alpha=0.4, size=5) +
theme(legend.position = "none") +
xlim(c(-10, 10)) + ylim(c(0, 15)) +
xlab("log2 fold change") + ylab("-log10 p-value")
g
How can I check that $p.value is numeric
I have used str P.value and its result is
The error message doesn't match the command you wrote you used, command states log2Foldchange, error states log2FOldchange. What is the output of
str(gene_list)?
also
I used this code and got these errors I have no idea
gene_list$threshold = as.factor(abs(gene_list$Foldchange) > 2 & gene_list$P.Value < 0.05)
g = ggplot(data=gene_list, aes(x=Foldchange, y=-log10(P.value), colour=my_palette)) +
geom_point(alpha=0.4, size=5) +
theme(legend.position = "none") +
xlim(c(-10, 10)) + ylim(c(0, 15)) +
xlab("log2 fold change") + ylab("-log10 p-value")
g
So you are trying to plot a column which doesn't exist. Your command specifies "log2Foldchange" but in the output of str() I see the name of the column is Foldchange.
It might be useful to first follow some basic R tutorials.
you right I am new to R can you help me to find out the problem
xlab("log2 fold change") + ylab("-log10 p-value")
g
I change this as well but still the error g object is not fiund
Please read a tutorial on R or ask your advisor or colleges for basic R problems.
can you suggest me some relvant helpful tutrioal cz I am in pure life science lab I have no help
See this page for example but you can search for others, like this or this other, I hope this helps. I would also advise to search your programming problems in Stack Overflow, there you can find almost all the errors you can encounter.
hi
with(res, plot(Foldchange, -log10(P.value), pch=20, main="Volcano plot", xlim=c(-5,5)))
with(subset(res, padj<.05 ), points(Foldchange, -log10(P.value), pch=20, col="red"))
with(subset(res, abs(Foldchange)>1), points(Foldchange, -log10(P.value), pch=20, col="orange"))
with(subset(res, padj<.05 & abs(Foldchange)>1), points(Foldchange, -log10(P.value), pch=20, col="green"))
# Label points with the textxy function from the calibrate plot
library(calibrate)
with(subset(res, padj<.05 & abs(Foldchange)>1), textxy(Foldchange, -log10(P.value), labs=Gene, cex=.8))
I have used this graph
it worked but still a problem it says
but it produces the graph with black and orange colour which means the lines which have object padj does not work? is padj is any defulat object cz I changed its name but still it does not work if its deault object so what sthe solution ?