peach works with .Q.hg, but I haven’t seen the “Protocol not available” error message before.
Is it possible that IEX doesn’t allow parallel requests from the same computer, or am I doing something wrong.
-Anuj
p.p1 {margin: 0.0px 0.0px 0.0px 0.0px; font: 11.0px Menlo; color: #d0d2da; background-color: #161821; background-color: rgba(22, 24, 33, 0.95)}p.p2 {margin: 0.0px 0.0px 0.0px 0.0px; font: 11.0px Menlo; color: #d0d2da; background-color: #161821; background-color: rgba(22, 24, 33, 0.95); min-height: 13.0px}span.s1 {font-variant-ligatures: no-common-ligatures; color: #9db9e0}span.s2 {font-variant-ligatures: no-common-ligatures}KDB+ 3.6t 2017.11.06 Copyright (C) 1993-2017 Kx Systems
m32/ 4()core 8192MB x x 10.10.122.3 NONEXPIRE
q)\s
4i
q)g
{.Q.hg`$(“http://goanuj.freeshell.org/go/“,x,”.txt”)}
q)
q)g peach (“AAPL”;“FB”)
“"AAPL",17.92\n”
“"FB",42.02\n”
q)gx
{
u1:“https://api.iextrading.com/1.0/stock/market/batch?symbols=”;
u2:“&types=quote,stats&filter=peRatio,priceToSales,priceToBook,returnOnEquity,marketCap”;
t:.j.k .Q.hg`$(u1,(","sv x),u2);
t:s
pemcap
pspb
roe xcol ( sym:key t),'exec (quote,'stats) from value t
}
q)rnp
{ (,/)gx peach (25 cut read0 x) }
q)rnp[`list_bank.txt]
'conn. OS reports: Protocol not available
[4] (.Q.hmb)
[3] /Users/agoyal3/github/data/z_scripts/y.q:62: gx:
u2:“&types=quote,stats&filter=peRatio,priceToSales,priceToBook,returnOnEquity,marketCap”;
t:.j.k .Q.hg`$(u1,(","sv x),u2);
^
t:s
pemcap
pspb
roe xcol ( sym:key t),'exec (quote,'stats) from value t
[1] /Users/agoyal3/github/data/z_scripts/y.q:73: rnp:{ (,/)gx peach (g:25 cut s:read0 x) }
p.p1 {margin: 0.0px 0.0px 0.0px 0.0px; font: 11.0px Menlo; color: #d0d2da; background-color: #161821; background-color: rgba(22, 24, 33, 0.95)}span.s1 {font-variant-ligatures: no-common-ligatures}