Trying to use sweave and rmarkdown in emacs. I keep getting
File mode specification error: (wrong-type-argument stringp \.)
when trying to create either an .rmd file or .rnw file. Here is my .emacs init file. Poly-r, polymode and ESS are all downloaded from melpa.
(unless (package-installed-p 'polymode)
(package-refresh-contents)
(package-install 'polymode))
;; Load Poly-R mode
(require 'poly-R)
;; Associate R files with Poly-R mode
(add-to-list 'auto-mode-alist '("\\.[rR]md'" . poly-markdown+r-mode))
(add-to-list 'auto-mode-alist '("\\.[rR]nw'" . poly-noweb+r-mode))