@dalanicolai's answer is correct but you still have a problem: the legal values of the :tangle header are the strings yes, no or a filename, (IOW, the argument always has to be a string), so your elisp snippet has to be more complicated: #begin_src shell :tangle (if (not file-exists-p "foo") "foo" "bar") ... Your original ...


From the org-documentation we find that the filename should be passed as a string (see section FILENAME), so you should place the latter ~/bin/eto between double quotes also.


Your problem comes from an interaction between R and org syntax. The strings *Type* and *Value* are fine for org mode columns, but are invalid object names (or column names) in R. Consequently, when you pass them to R, the leading * is converted to X., and the trailing * is converted to .. You can fix this by removing the asterixes (asterii?) from your table:...

Only top voted, non community-wiki answers of a minimum length are eligible