丹东玫瑰港湾酒店:Compiling The kdb/R interface on Win32 ? The Research Kitchen Weblog
来源:百度文库 编辑:偶看新闻 时间:2024/05/05 03:23:58
Compiling The kdb/R interface on Win32
I have been playing with the kdb/R interface from kx.com,and had some problems installing with Cygwin gcc. It may be possible toget this to work with Cygwin gcc + a Win32 threads library, but in themeantime I installed MinGW, and it works perfectly. Here are the steps(basically as per the kx docs):
1. Download c.o from here: http://kx.com/q/w32/
2. gcc -c base.c -I. -I "${R_HOME}/include/"
3. gcc -Wl,--export-all-symbols -shared -o qserver.dll c.o base.o ${r
-HOME}/bin/R.dll -lws2_32
The resulting qserver.dll can be loaded via dyn.load()
, and then (just using the qserver.R supplied by kx) from within R:
source("qserver.R")
conn < - open_connection("server", 12345)
result <- execute(conn, "select avg bid by sym from fx_quote")
x <- as.data.frame(mapply(FUN=c, result))
> head(x, 10)
V1 V2
1 AUD= 0.792402880224811
2 AUD=D2 0.791632149468651
3 AUD=EBS 0.790402776387278
4 AUDCHF=R 0.85955071021153
5 AUDJPY=R 75.0707755671935
6 BRL= 1.97194091379422
7 CAD= 1.15980648929715
8 CAD=D2 1.15962545479939
9 CAD=EBS 1.14104373919176
10 CADJPY=R 81.6389284332255
Trojan.PSW.Misc.kdb
有谁知道什么是kdb格式
Compiling...Error spawning cl.exe
who knows the meaning of R in case of R v Cork,R v Coombridge,R v Sweetman,etc?
There is a lot of --a-- --r in the sea.
what r the differences between embassy and consulate?
The Cranberries和Avril R. Lavigne 最好听的歌
Avril R. Lavigne 和The Cranberries最好听的歌
急求K&R《the C programming language》电子版
u r the best in my heart forever
the seller shall promptly inform the buyer of such change r
emacs's segment fault when compiling on fedora5
有首歌里面唱:dong't think u r the first, in the whole universe……
i\'m going to the States about the end of this September.\r\nactually
R n B歌曲开头常有“check the self”什么意思..?
『英语猜谜』『Why is the letter “R” like Christmas?』
There is a lot of __ a __ __ r in the sea
ibm notebook T X or R series what's the diffient
F.I.R.的无限专辑中刺鸟the legend传说的英文旁述
推荐Avril R. Lavigne 和The Cranberries最好听的歌
推荐The Cranberries和Avril R. Lavigne 你认为最好听的歌
Sen. Susan Collins, R-Maine, chairwoman of the Senate Homeland Security 是什么意思?
哪里可以下载The 3 R's Lyrics的歌词?
Speech on Hitler's Invasion of the U.S.S.R