Oh, thanks so much! It fixed my problem. But, is there a way to just write 
PhyNode(blah, blah, blah) instead of the cumbersome MyClasses.PhyNode ? I 
tried using MyClasses and it reported the same error as well.

On Friday, 16 September 2016 12:11:18 UTC+2, randm...@gmail.com wrote:
>
> The error I'm getting is something like 
>
> ERROR: LoadError: UndefVarError: PhyNode not defined
>
> So since you used importall instead of using, you need to the qualified 
> MyClasses.PhyNode. If you do, you'll probably get some error about
>
> ERROR: LoadError: MethodError: `convert` has no method matching 
> convert(::Type{MyClasses.PhyNode{T}}, ::Int64, ::ASCIIString, ::Float64, 
> ::Float64)
>
> unless you have another constructor for PhyNode, since you need to 
> provide the two vectors for inEdges and outEdges as well. Long story 
> short: Something like 
>
> push!(nodelist, MyClasses.PhyNode(1, Atlanta, 32.3, 54.7, [], []))
>
> should work, though you should probably specify the type and maybe size of 
> the vectors (depending on what you want to do with them).
>
> Am Freitag, 16. September 2016 10:02:08 UTC+2 schrieb varu...@gmail.com:
>>
>> The files are indeed in the same directory and I also added the path of 
>> these files to the variable LOAD_PATH as well. But still, I get the same 
>> error.
>>
>> On Friday, 16 September 2016 09:49:45 UTC+2, Lutfullah Tomak wrote:
>>>
>>> It is related to the `importall` part of code. It can be that the files 
>>> are not in the same directory but I'm not sure. Also, [] creates an Array 
>>> with element type of Any. Giving it a type annotation may help peeformance 
>>> ei TypeofArray[].
>>
>>

Reply via email to