test 6

This file can be loaded into whatever editor you like to use for knitr. ghc is called for the second code block.

library(knitr)
opts_chunk$set(engine = "haskell", engine.path = "ghc")
:set -XQuasiQuotes
:module +RlangQQ
let fibs = 0.0:1: zipWith (+) fibs (drop 1 fibs)
[r| png('test6_fig1.png'); plot(1:20, $(take 20 fibs)); dev.off() |]
test6 caption here

test6 caption here

limitations