I'm trying to extend DataFrames so that I can include metadata on the 
dataframe and the columns.  Unfortunately, from the way I understand how 
Julia works, this is not an easy task. It seams as though I pretty much 
have to copy the existing dataframes.jl file and replace all of the 
"DataFrame" references with "MyDataFrame", then add in the metadata parts 
where needed (or use composition and proxy all of the DataFrame 
interfaces).  This method seems to work for some things (it works with 
Gadfly), however, I can't seem to get ncol and nrow to work properly.  When 
I try to do "size(mydf)", I get the following error:

    `nrow` has no method matching nrow(::MyDataFrame)

However, if I do "methods(nrow)", it displays this:

   nrow(df::MyDataFrame)

Which is exactly what the previous message said didn't exist.  I'm a little 
puzzled as to why DataFrames' original nrow doesn't show up in that output 
as well since it is exported.  When I do a "using DataFrames" in this same 
session.  I get the following warning.

   Warning: using DataFrames.nrow in module Main conflicts with an existing 
identifier.

I think it's safe to say that I'm pretty confused at this point.  I'd 
appreciate it if someone could clarify how extending existing structures is 
supposed to work.


Reply via email to