Hi Sofia, welcome!, is better if you make your questions with a REPRoducible EXample (reprex) but here is an example with some built-in data
library(dplyr)
library(ggplot2)
sample_data <- iris[,c("Sepal.Width", "Sepal.Length")]
sample_data %>%
filter(Sepal.Length <= 4.6) %>% # Filtering up to a maximum value
ggplot(aes(Sepal.Length, Sepal.Width)) + # Ploting the result
geom_point()

Created on 2019-03-10 by the reprex package (v0.2.1)
If you've never heard of a reprex before, you might want to start by reading this FAQ: