Try:
edit(vignette("grobs",package = "grid"))
(edit is a method. It looks at the class of the first entry, name, to identify
which method to use. See ?edit. You want it to use edit.vignette, so you need
to drop 'file=' so you pass the vignette to edit as the first argument or
name=. Then edit will pass it to edit.vignette and it'll work. Or go direct:
edit.vignette(vignette("grobs",package = "grid")). See ?vignette. Maybe the use
of name as the first argument of a method is a little misleading? But you can
work out what is going if you work through the help documentation.)
Karl
Message: 9
Date: Sun, 7 Sep 2014 17:06:44 +0800 (CST)
From: "PO SU" <[email protected]>
To: "R. Help" <[email protected]>
Subject: [R] using edit to extract codes from vignette failed
Message-ID: <[email protected]>
Content-Type: text/plain; charset=UTF-8
Dear expeRts,
? ? When i using the following code, i get a error as follows:
?edit(file=vignette("grobs",package = "grid"))
Error in edit.vignette(file = vignette("grobs", package = "grid")) :?
? argument "name" is missing, with no default
I investigated edit function, but still can't ?get codes from a vignette, May
you help me?
--
PO SU
mail: [email protected]
Majored in Statistics from SJTU
______________________________________________
[email protected] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.