cannot add smooth line
See original GitHub issueI would like to add a smooth line through a scatter plot, so far I’m aiming at two solutions:
(ggplot(A_phsA, aes('timestamp', 'A_phsA'))
+ geom_point(color = 'blue')
+ xlab("2018 - 2019")
+ ylab("Phase current A [A]")
+ scale_x_datetime(breaks=date_breaks('1 month'), labels=date_format('%m %Y'))
+ geom_line(stat="smooth", method="loess", alpha=0.7)
+ theme(figure_size=(11, 6), axis_text_x=element_text(rotation=45))
)
(ggplot(A_phsA)
+ aes('timestamp', 'A_phsA')
+ geom_point(color = 'blue')
+ xlab("2018 - 2019")
+ ylab("Phase current A [A]")
+ scale_x_datetime(breaks=date_breaks('1 month'), labels=date_format('%m %Y'))
+ geom_smooth(alpha = 0.1)
+ theme(figure_size=(11, 6), axis_text_x=element_text(rotation=45))
)
but none is working. What am I doing wrong?
Issue Analytics
- State:
- Created 4 years ago
- Comments:5 (3 by maintainers)
Top Results From Across the Web
smooth line missing - Microsoft Community Hub
If you look at the Insert Chart dialog and select the "All Charts" tab, you'll only see smoothed lines in the xy (scatter)...
Read more >How to add a smooth line using ggplot2 in a plot with 2 ...
I am trying to make a scatter plot with 2 different datasets and a smooth line of each scatter to compare them.
Read more >Smooth Tool in Illustrator - eduCBA
With this smooth tool, the user can make pencil sketches and drawings look smoother and glossier without any rough edges. How to Use...
Read more >How To Smooth Lines In Illustrator CC - YouTube
Learn how to smooth lines in Adobe Illustrator CC in this super quick and easy tutorial. ... Your browser can't play this video....
Read more >Why can't I get smooth lines? - Affinity | Forum
I want my lines to be smooth, but I keep ending up with horribly choppy lines. My canvas is 1920x1080p 300 dpi. I'm...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@jtrakk , I was mistaken, this is not a bug. The issue is the date column is a string. It needs to be the correct type.
I see. In that case it would be nice to have a helpful exception message instead of silent failure.