[Rcpp-devel] Integrate xts_API for C with Rcpp
Dirk Eddelbuettel
edd at debian.org
Fri Jan 11 20:46:23 CET 2013
On 12 January 2013 at 02:23, Wu Wush wrote:
| > A few quick questions to focus the discussion:
| > - Do you have particular functions from the xts C API in mind?
| > - Is what you are looking for already exported?
| > - Is it in xts or in zoo? Would be need both?
| > ---
| > My question was about which C function in the xts API, and which unexported
| > functions. We could start getting to those (particularly the exported ones).
| >
|
| There is a document of xts API. Please check `help("xtsAPI")` in R
| with xts(0.9-1).
Got it, thanks. I had gone straight to the header file included in the package.
| In my experience, we could write some functions based on exposed API:
| - Query a subset of xts object based on row
| subset(`Rcpp::DatetimeVector` or integer vector) and column
| subset(string vector or integer vector)
| - Convert `Rcpp::Matrix<RTYPE>` instance to xts object with given
| index(`DatetimeVector`)
Simple helper functions may be a first start.
| I have implemented these features, so I only need a skeleton of
| Rcpp-like package. Could you give me some suggestion about this?
There is a vignette about that, and dozens of posts on this list,
StackOverflow, blogs, ... but now that I more or less committed to a stub
package let me get started on one.
| > | In my opinion, it might be convenient if there is a c++ class `XtsNumericMatrix
| > | ` or `XtsIntegerMatrix` which can handle the special attributes such as `index`
| > | of xts objects easily.
| >
| > That could come once we have basic access to xts, but I am unlikely to
| > drive. Maybe a user (you?) wants to do it, maybe we offer it as a GSoC project.
| >
|
| Well, I might do it if I use Rcpp and xts in another project.
|
| I love Rcpp, so I am glad to do some contribution to it. :)
That's the spirit :)
Dirk
--
Dirk Eddelbuettel | edd at debian.org | http://dirk.eddelbuettel.com
More information about the Rcpp-devel
mailing list