mergeData {RSurvey} | R Documentation

## Merge Time-stamped Data

### Description

This function merges temporal data with the current time-stamped survey data.

### Usage

    mergeData(file = NULL)

### Arguments

`file` | either a character string naming a file or a connection.

### Format

The tab delineated temporal file, ‘*.txt’, contains the following variables:

`[,1]` | character | date/time
`[,2:]` | numeric | state variables

The first `[1,]` and second `[2,]` rows are reserved for column descriptors and units, respectively. Units associated with date/time values are based on format character strings described in `strptime`.

### Value

The `cols` and `data.raw` components of `srvy.dat` are replaced by the merged data set.

### Note

This function is not currently accessible through a GUI.

### Author(s)

Fisher, J. C.

### See Also

`approx`

### Examples

    f <- system.file("RSurvey-ex/river.txt", package = "RSurvey")
    con <- file(f, open = "r", encoding = "latin1")
    d <- readFile(con)
    srvy.dat("cols", d$cols)
    srvy.dat("vars", d$vars)
    srvy.dat("data.raw", d$dat)

    f <- system.file("RSurvey-ex/river-temperature.txt", package = "RSurvey")
    con <- file(f, open = "r", encoding = "latin1")
    mergeData(con)
    srvy.dat("cols")
    srvy.dat("data.raw")

[Package RSurvey version 0.4.5 Index]