| Title: | Read Key/Value Pair Observations |
| Version: | 0.1 |
| Type: | Package |
| Description: | This package provides functionality to read files containing observations which consist of arbitrary key/value pairs. |
| Depends: | R (≥ 3.1.0) |
| Imports: | Rcpp (≥ 0.11) |
| License: | GPL-3 |
| LazyData: | true |
| LinkingTo: | Rcpp |
| Packaged: | 2014-07-05 20:44:05 UTC; vst |
| Author: | Vehbi Sinan Tunalioglu [aut, cre] |
| Maintainer: | Vehbi Sinan Tunalioglu <vst@vsthost.com> |
| NeedsCompilation: | yes |
| Repository: | CRAN |
| Date/Publication: | 2014-07-06 00:16:50 |
Read Key/Value Pair Observations
Description
This package provides functionality to read filescontaining observations which consist of arbitrarykey/value pairs.
Read key/value pair observations.
Description
Provides the workhorse function to read key/value pairobservations from a flat file. Note that, same keys andcorresponding values in the same observation are returnedas vectors.
Arguments
path | The path to the input file. |
delim_tuple | The tuple deliminator. |
delim_field | The field deliminator. |
Value
A list of observations. Each observation is a named list ofkey/value pairs.
Examples
## Not run: ## Assume that we have a file at path "file.dat" with the## following contents:#### key1=value11;key2=value12## key1=value21;key2=value22## key1=value31;key2=value320;key2=value321#### Let's read this in and display as a matrix:observations <- readkvs("file.dat", ";", "=")do.call(rbind, observations)## End(Not run)