I am have problems tyring to input a .Rtex file into my shareLatex project using the /input{file} or include{file} commands.
Is there a way to include this as you can do with other .tex files?
The file looks like this :
<<>>=
# Create a sequence of numbers
X = 2:10
# Display basic statistical measures
summary(X)
@
The code is compiled if I put it in the main.Rtex file, but not if I try to include it. This questions is similar to the one on tex.stackexchange.
The following works in Overleaf (main file named *.Rtex).