This kind of subset operation is no longer possible. It doesn't make sense in a 
language without ubiquitous delayed evaluation.

Can I ask what docs you found this operation described in? We should take them 
down, because they're clearly out-of-date.

 -- John

On Sep 14, 2014, at 4:12 PM, Arshak Navruzyan <[email protected]> wrote:

> I can't get either subset syntax working for some reason.  I tried to 
> 
> Pkg.installed("DataFrames")
> 
> v"0.5.7"
> 
> 
> df = DataFrame(A = 1:4, B = ["M", "F", "F", "M"])
> 
> sub(df,:(A .== "M"))
> 
> `getindex` has no method matching getindex(::SimpleIndex, ::Expr)
> while loading In[72], in expression starting on line 13
> 
>  in sub at 
> /Users/arshakn/.julia/v0.3/DataFrames/src/subdataframe/subdataframe.jl:97
> df[:(A % 2 .== 0),:] 
> 
> `getindex` has no method matching getindex(::DataFrame, ::Expr, 
> ::UnitRange{Int64})
> while loading In[73], in expression starting on line 15

Reply via email to