using the starwars dataframe in ggplot, How do you remove the outlier in this scatter plot?
plot.settings <- ggplot(starwars, aes(x = height, y = mass)) +
labs(x = "height", y = "mass") +
theme_classic()
plot.settings + geom_point()
And here is the graph with the name of the clear outlier
You could use dplyr::filter to remove the row relating to that name in the dataframe.
system
Closed
3
This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.
If you have a query related to it or one of the replies, start a new topic and refer back with a link.