Learn R Programming

gdsfmt (version 1.8.3)

print.gds.class: Show the information of class "gds.class" and "gdsn.class"

Description

Displays the contents of "gds.class" (a GDS file) and "gdsn.class" (a GDS node).

Usage

"print"(x, ...) "print"(x, expand=TRUE, all=FALSE, attribute=FALSE, attribute.trim=FALSE, ...) "show"(object)

Arguments

x
an object of class gds.class, a GDS file; or gdsn.class, a GDS node
object
an object of class gds.class, the number of elements in the preview can be specified via the option getOption("gds.preview.num", 6L), while 6L is the default value
expand
whether enumerate all of child nodes
all
if FALSE, hide GDS nodes with an attribute "R.invisible"
attribute
if TRUE, show the attribute(s)
attribute.trim
if TRUE, trim the attribute information if it is too long
...
the arguments passed to or from other methods

Value

None.

References

http://github.com/zhengxwen/gdsfmt

Examples

Run this code
# cteate a GDS file
f <- createfn.gds("test.gds")

add.gdsn(f, "int", 1:100)
add.gdsn(f, "int.matrix", matrix(1:(50*100), nrow=100, ncol=50))
put.attr.gdsn(index.gdsn(f, "int.matrix"), "int", 1:10)

print(f, all=TRUE)
print(f, all=TRUE, attribute=TRUE)
print(f, all=TRUE, attribute=TRUE, attribute.trim=FALSE)

show(index.gdsn(f, "int"))
show(index.gdsn(f, "int.matrix"))

# close the GDS file
closefn.gds(f)

# delete the temporary file
unlink("test.gds", force=TRUE)

Run the code above in your browser using DataLab