Label x-axis nearest to thousand in ggplot
<p>I want to use scale_x_continuous and round my labels to nearest thousand. For example if my X axis are 1234567,2345566.... I want it to be 1235,2346.I have used sequencing to split my x-axis in deciles. When I am rounding it to thousands and then dividing by 1000 I will show it by example. Its making 1235000 and after dividing its becoming 1235 which I want but since sclae_x_continuous observes that all the numbers till 3million(which is now 3k) comes in the first decile its printing all the labels at the same place. The code I am using is:</p>
<pre><code>ggplot(
  data = cummulative, 
  aes(
    x = seq(1,length(cummulative$Frequency)),
    y = Cum.Percent.,
    group = 1
  )
) + 
geom_line(colour=&quot;red&quot;, size=1) + 
theme_classic() + 
theme(axis.text.x = element_text(angle = 75, hjust = 1, size=8)) + 
labs(x=&quot;Number of Customer (in thousands)&quot;,y=&quot;Product Share (%)&quot;) +
ggtitle(&quot;Pareto Chart&quot;) +ylim(0,100.1) +
(scale_x_continuous(
  breaks = seq(
    0, 
    length(cummulative$Frequency), 
    length(cummulative$Frequency)/10
  )
))    
</code></pre>
<p>Please also find the image here:<a href="https://i.stack.imgur.com/6AvfA.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/6AvfA.png" alt="enter image description here" /></a></p>
<p>Thanks a lot guys :)</p>