I am extremely new to R. This simple code prints two outputs:
ec_lineal = function(a,b){
print(sprintf('%i x + %i = 0',a,b))
paste(sprintf('x ='), -b / a)
}
ec_lineal(5,3)
[1] "5 x + 3 = 0"
[1] "x = -0.6"
When I knit the code to HTML, I get separate boxes for each of the outputs:
Is there any way to combine both outputs in a single white box?
Maybe editing the code chunk header ```{r}
?
I am using R 3.6.3 and the latest version of RStudio in Windows 10.
Thank you.