I have a problem with child files in knitr. The caching works fine, but the dependencies do not work. My sandbox example looks like that:
\documentclass{article}
\begin{document}
<<setup, cache=FALSE>>=
opts_chunk$set(cache=TRUE, autodep=TRUE)
dep_auto() # figure out dependencies automatically
@
<<a>>=
x <- 14
@
<<b>>=
print(x)
@
<<child, child='child.Rnw', eval=TRUE>>=
@
\end{document}
With the 'child.Rnw' looking like this:
<<child>>=
print(x)
@
When I now compile the code, then change x in chunk a and then compile it again: chunk b reacts properly, but the child does not. Am I doing something obviously wrong?
Thanks for the help!