Question: Making a package installable ?

Dear Maple Users, 

 

First of all I would like to thank for your great support and hints on making a package for Maple. It has made possible for me to construct this package here: 

 

restart; 
MyMat:=module()
description "My Package";
option package; 
export RegModelPlot,RegModel;
RegModelPlot :=proc(c::algebraic,xd::list,yd::list,x::algebraic)
    uses Statistics, plots:
     display
                            (  [ plot
                                 ( Fit(c, xd, yd, x),
                                   x=min(xd)..max(xd),
                                   color=blue,gridlines,
                                   title=typeset("Regressionformula\n f(x) = ", evalf[4](Fit(c, xd, yd, x))),caption=typeset("Residuals = ", Fit(c, xd, yd, x, output = residuals) ))                    
                                 ,
                            
                                 plot
                                 ( xd, yd,
                                   style=point,
                                   symbol=solidcircle,
                                   symbolsize=10,
                                   color=red
                                 )
                               ],
                               size=[800,600]
                            );
                           
                           end proc; 

    RegModel:=proc(c::algebraic,xd::list,yd::list,x::algebraic)
            uses Statistics, plots:
return  Fit(c, xd, yd, x);
end proc; 
    end module

 

My question is now. How do I make it installable ? Meaning, making it so I can be accessed using with the with() argument alene? I have tried to convert it to into an MLA-file and place it in the lib folder. 
 

But if I type with(MyMat) it gives me the error: 

Error, invalid input: with expects its 1st argument, pname, to be of type {`module`, package}, but received MyMat 
 

So anyone with an idea/hint on what I need to add to make the package installable? 

 

Thanks in advance :)

Please Wait...