Description Usage Arguments Details Value
View source: R/SpikeRemovalFunctions.R
This function is not exported
1 2 3 4 5 6 7 8 9 10 11 | dspk.TableFormatting(
Data = NULL,
Value,
DateTime = NULL,
NAvalue = NULL,
datetime.format = NULL,
datetime.timezone = "GMT",
state.of.value.code = 110,
state.of.value.code.na = 255,
add.original.data = T
)
|
Data |
a datatable or NULL |
Value |
a vector, column number or column name |
DateTime |
a vector, column number, column name or NULL. If left NULL then a time will be generated by numbering the records consecutivly. |
NAvalue |
NULL or the value to be turned to NA |
datetime.format |
If date time is in character format then a format must be given so it can be converted to POSIX format. Character string giving the datetime format. See strptime() documentation for additional help. |
datetime.timezone |
Character string giving the time zone of the datetime. By default “GMT”. See strptime() documentation for additional help. |
state.of.value.code |
State of value to give all non-NA values |
state.of.value.code.na |
State of value to give all NA values |
add.original.data |
If TRUE then all original data in the provided datatable will be included in the output data table |
Puts data values and datetime in a unique column and creates a state of value column. If the state of value column "dspk.StateOfValue" already exists then those values will be kept as the state of values. if datetime is numeric then those values will be kept. If date time is a character format, then it will be converted into UNIX seconds. If datetime is missing then the records will be numbered cosecutivly.
data table with values in "dspk.Values", numeric datetime in "dspk.DateTimeNum", and state of value in "dspk.StateOfValue". if add.original.data is TRUE then all the data in the input data table will be included.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.