This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Changing the x-axis in ggseqlogo in R

I have a sequence logo of 21 bases. I have generated a sequence logo using ggseqlogo and the x-axis goes from 1-21. I would like to be able to change the x-axis to read -10-+10. Does anyone know how to do this?

r sequence ggseqlogo

1 answer

Untested but adding + scale_x_continuous(breaks=1:21, labels=-10:10) to the returned ggplot2 object should work.

Thank you! That works!

I've moved the comment to an answer. Please accept it to mark the post as solved.

Log in to answer this question.