MathGroup Archive 1998

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: creating packages



steve wrote:
> 
> Hi,
>         I would like to create a package from a notebook.
>         I followed the directions in the Mathematica book, but the
>         resulting m file was not a package. After applying
>         "Save-as-special|package"  all the
>         expressions appeared to be enclosed in comments.
> 
>         Could someone explain how to create a package from a
>         notebook.
> 
>         steve


Steve,

Only input cells with the property Initialization Cell (set by
Menu>Cell>Cell Properties) will not be enclosed in comments. Everything
is put into one initialization cell.

So you need to put the expressions that you want to compute with in
initialization cells.

This method will include everything in your notebook - including the
PostScript code for any graphics. If you don't want this then you could
make a copy of the parts that you do want.

Alternatively, the first time that  you save a notebook which has
initilization cells you will be asked whether you want to create a
package containing the initialization input cells. This would be linked
to the notebook and updated as the notebook is later saved.

-- 
Allan Hayes
Mathematica Training and Consulting
Leicester, UK
hay@haystack.demon.co.uk
http://www.haystack.demon.co.uk
voice: +44 (0)116 271 4198
fax: +44 (0)116 271 8642




  • Prev by Date: Re: problem with Coefficient
  • Next by Date: Re: Mathematica Fonts question
  • Prev by thread: Re: creating packages
  • Next by thread: reloading the program