Macros aren't what you want here. The more appropriate tool for this job is a simple local function that knows both the old and new arguments to cc
and handles printing out the graphviz text and making the recursive call:
(define (cc amount kinds-of-coins)
(let ((recur (lambda (new-amount new-kinds)
(begin
(display "\"")
(display `(cc ,amount ,kinds-of-coins))
(display "\"")
(display " -> ")
(display "\"")
(display `(cc ,new-amount ,new-kinds))
(display "\"")
(display "\n")
(cc new-amount new-kinds)))))
(cond ((= amount 0) 1)
((or (< amount 0) (= kinds-of-coins 0)) 0)
(else (+
(recur amount (- kinds-of-coins 1))
(recur (- amount (first-denomination kinds-of-coins)) kinds-of-coins))))))
You didn't say what Scheme implementation you're using, but for some implementations there are some minor syntactic cleanups that can be done as well to make this code look nicer.