Displaying 4 results from an estimated 4 matches for "floatvector".
Did you mean:
flagvector
2009 Nov 19
3
Issue when calling deparse(substitute(x)) from C with "anonymous" R vectors ?
...forum_name=rpy-list
), but it will likely be present in other bridges to R as well.
#using R-2.10 and rpy2-2.1.dev
>>> import rpy2.robjects as robjects
>>> f = robjects.r('''function(x) return(deparse(substitute(x)))''')
>>> tuple(f(robjects.FloatVector(range(17))))
('c(0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16)',)
# length 1
>>> tuple(f(robjects.FloatVector(range(18))))
('c(0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17', ')')
# length 2 !!
Does it seem to others like an issue prese...
2010 May 19
1
Why does my RPy2 program run faster on Windows?
...ate" %(cds,bm,cds,bm)):
d1.append(str(row[0]))
v1.append(row[1])
v2.append(row[2])
t4=datetime.now()
t1=datetime.now()
print "Calculating"
d1.pop(0)
d1vec = robjects.StrVector(d1)
v1vec = robjects.FloatVector(v1)
v2vec = robjects.FloatVector(v2)
r1 = r('Return.calculate(%s)' %v1vec.r_repr())
r2 = r('Return.calculate(%s)' %v2vec.r_repr())
tl = robjects.rlc.TaggedList([r1,r2],tags=('Geo','Nifty'))
df = robjects.DataFrame(tl)...
2013 Mar 07
0
initial starting values with constOptim()
...s. For example I have 11 parameters to estimate (let's
call the parameters as pam1..pam11) and their true value is:
pam1=0.2 pam2=0.3 pam3=0.4 pam4=0.7 pam5=0.55 pam6=0.45 pam7=0.1 pam8=0.01
pam9=0.01 pam10=45 pam11=45
In the contrtOptim() I am setting the starting parameters as:
start_param=FloatVector((pam1,pam2,pam3,pam4,pam5,pam6,pam7,pam8,pam9,pam10,pam,11))
where I set the starting values. I have observed that when I am using
different sets of starting values the results change. For example when I am
using the set
start_param=FloatVector((0.2,0.3,0.4,0.6,0.7,0.8,0.3,0.011,0.011,15,15))
an...
2011 Oct 17
0
rpy2 pie chart
...20%
E 10%
filename = './testing.png'
grdevices = importr('grDevices')
rdevices.png(file=filename, width=1200, height=800)
dataf = Robjects.DataFrame({'pathways':Robjects.StrVector(Pathways),
occurrences' :
Robjects.FloatVector(Occurrences)
})
pie = ggplot2.ggplot(dataf)+ \
ggplot2.aes_string(x='',fill='pathways',weight="amounts")+\
ggplot2.geom_bar(width=1)+\
ggplot2.coord_polar(theta="y")
pie.plot()
grdevices.dev_off()
but this...