I think you're actually close to a reprex. You should provide the code in your question instead of a screenshot so someone who wants to help can copy and paste directly into R.
Since you are asking a question about a RMD, you should also include information in the YAML header so we can see what kind of document your are making.
We also have a FAQ on making a reprex for R beginners, because it can feel really difficult when you're just getting started: FAQ: How to do a minimal reproducible example ( reprex ) for beginners