In regular R code I can do the following (when I put pointer at long_string
and execute:
long_string <- 'a
b'
So if I have a very long string then I can just hit Enter
to split it and R Studio will understand.
In R-markdown the above does not work
```{r string test, echo = F}
long_string <- 'a
b'
```
If I put pointer at long_string
and execute, I will end up with +
in console, meaning that R is expecting end of line command.
One solution is to select whole expression (multiple lines) and run it, but I wonder if there are other solutions.