text2times: Parses a text string for time information.

Description Usage Arguments Value Author(s) References See Also Examples

View source: R/functions.R

Description

This function take a text string and returns any time-specific information that it finds.

Usage

1
text2times(text, session=getCurlHandle())

Arguments

text

A text string containing possible time information.

session

This is the CURLHandle object giving the structure for the options and that will process the command. For curlMultiPerform, this is an object of class code MultiCURLHandle-class.

Value

A data.frame containing

duration

Length of time in seconds of the recognized event.

start_index

The beginning of the matched string in the original string.

is_relative

Logical value for matched string.

end_index

The end of the matched string in the original string.

time_seconds

The unix timestamp of the event (time since epoch).

matched_string

The string that was used in the processing of the request.

time_string

The time string of the recognized time event.

Author(s)

Ryan Elmore

References

text2times

See Also

curlPerform, getCurlHandle, dynCurlReader

Examples

1
2
3
4
5
	## Not run: 
		text <- "02/01/2010, Meeting this Wednesday"
		text2times(text)
	
## End(Not run)

RDSTK documentation built on May 29, 2017, 8:30 p.m.