Hello and welcome!
There isn't much to go on to help you. I am not sure I follow the issue you're having Can you provide a small reprex of what you're doing?
Assuming you're in an R Markdown document - You mention this is in a report a few times so my best guess is you're in an R Markdown report, and the report is showing the full text string result of your gsub. One way to handle that is to assign that to a new object. That is, string <- gsub(...) instead of gsub(...). You also might consider changing the chunk options
https://rmarkdown.rstudio.com/lesson-3.html