Learn R Programming

hash (version 2.2.6.3)

hash-package: Hash/associative array/dictionary data structure for the R language.

Description

This S4 class is designed to provide a hash-like data structure in a native R style and provides the necessary methods for all general methods for hash operations.

Arguments

Author

Christopher Brown

Maintainer: Christopher Brown <chris.brown -at- decisionpatterns -dot- com>

References

http://www.mail-archive.com/r-help@r-project.org/msg37637.html

http://www.mail-archive.com/r-help@r-project.org/msg37650.html

See Also

See also hash , hash-accessors and environment

Examples

Run this code

  h <- hash( keys=letters, values=1:26 )
  h <- hash( letters, 1:26 )

  h$a # 1

  h$foo <- "bar"
  h[ "foo" ] 
  h[[ "foo" ]]

  clear(h)
  rm(h)

Run the code above in your browser using DataLab