Hi, all,
In Splus, how does one pass a 2 dimentional array to a
C subroutine?
For example, I have a matrix in Splus:
> dim(data)
[1] 845 13
The C function is declared as follows:
void Foo ( float ** something, int *Nrow, int * Ncol,
float * result)
So I call "Foo" this way:
> .C("Foo",as(data,"single"),as(845,"integer"),
as(13,"integer"),as(result,"single"))
Will this work? Is the 'something' variable in the C
routine an array of pointers, or is it just a array
with length (Nrow * Ncol)?
Any suggesting/reference will be greatly appreciated.
Thank you.
Dan
__________________________________________________
Do You Yahoo!?
Send instant messages & get email alerts with Yahoo! Messenger.
http://im.yahoo.com/
-----------------------------------------------------------------------
This message was distributed by s-news@wubios.wustl.edu. To unsubscribe
send e-mail to s-news-request@wubios.wustl.edu with the BODY of the
message: unsubscribe s-news
|